<commit_before>var api = require('./api');

var Releases = {

		/**
		 * Retrieves all releases
		 * 
		 * @param		object		release_query		[Description]
		 * @param		function		callback		[Description]
		 *
		 * @return		void
		 */
		__get_releases: function (release_query, callback) {
			api.handleRestRequest('get', '/releases', release_query, callback);
		},


		/**
		 * Retrieves one release
		 * 
		 * @param		integer		release_id		[Description]
		 * @param		function		callback		[Description]
		 *
		 * @return		void
		 */
		__get_releases: function (release_id, callback) {
			api.handleRestRequest('get', '/releases/' + release_id + '', null, callback);
		},


		/**
		 * {Custom comment here}
		 * 
		 * @param		object		release_data		[Description]
		 * @param		function		callback		[Description]
		 *
		 * @return		void
		 */
		__post_releases: function (release_data, callback) {
			api.handleRestRequest('postJson', '/releases', release_data, callback);
		},


		/**
		 * {Custom comment here}
		 * 
		 * @param		integer		release_id		[Description]
		 * @param		object		release_data		[Description]
		 * @param		function		callback		[Description]
		 *
		 * @return		void
		 */
		__post_releases: function (release_id, release_data, callback) {
			api.handleRestRequest('postJson', '/releases/' + release_id + '', release_data, callback);
		},


		/**
		 * {Custom comment here}
		 * 
		 * @param		integer		release_id		[Description]
		 * @param		function		callback		[Description]
		 *
		 * @return		void
		 */
		__delete_releases: function (release_id, callback) {
			api.handleRestRequest('delete', '/releases/' + release_id + '', null, callback);
		}

};

module.exports = Releases;
<commit_msg>Releases: Added API routes<commit_after>var api = require('./api');

var Releases = {

		/**
		 * Retrieves one/multiple releases
		 *
		 * @param		integer		release_id			Optional ID of specific release
		 * @param		object		filters				Optional filters if not getting by ID
		 * @param		function	callback			Callback function
		 *
		 * @return		void
		 */
		get: function () {
			var args = Array.prototype.slice.apply(arguments),
				callback = args.slice(-1).pop() || function() { },
				release_id = (args[0]) ? '/' + args[0] : '',
				filters = args[1] || null;

			api.handleRestRequest('get', '/releases' + release_id , filters, callback);
		},


		/**
		 * Add a new release
		 *
		 * @param		object		release_data		Data for a new release
		 * @param		function	callback			Callback function
		 *
		 * @return		void
		 */
		add: function (release_data, callback) {
			api.handleRestRequest('postJson', '/releases', release_data, callback);
		},


		/**
		 * Update an existing release
		 *
		 * @param		integer		release_id			ID of specific release
		 * @param		object		release_data		New data for an existing release
		 * @param		function	callback			Callback function
		 *
		 * @return		void
		 */
		update: function (release_id, release_data, callback) {
			api.handleRestRequest('postJson', '/releases/' + release_id + '', release_data, callback);
		},


		/**
		 * {Custom comment here}
		 *
		 * @param		integer		release_id			ID of specific release
		 * @param		function	callback			Callback function
		 *
		 * @return		void
		 */
		delete: function (release_id, callback) {
			api.handleRestRequest('delete', '/releases/' + release_id + '', null, callback);
		}

};

module.exports = Releases;

{'fraction_non_alphanumeric': 0.12948793407886994, 'fraction_numerical': 0.0011771630370806356, 'mean_word_length': 2.9707943925233646, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '179168', 'n_tokens_mistral': 1304, 'n_tokens_neox': 1063, 'n_words': 267}