<NME> omnisearch.js
<BEF> /**
 * Omnisearch initialisation.
 *
 * @mixin
 * @namespace Bolt.omnisearch
 *
 * @param {Object} bolt - The Bolt module.
 * @param {Object} $ - jQuery.
 * @param {Object} window - Window object.
 */
(function (bolt, $, window) {
    'use strict';

    /**
     * Bolt.omnisearch mixin container.
     *
     * @private
     * @type {Object}
     */
    var omnisearch = {};

    /**
     * Initializes the mixin.
     *
     * @static
     * @function init
     * @memberof Bolt.omnisearch
     */
    omnisearch.init = function () {

        var $select = $('.omnisearch select');
        $select.select2({
            width: '100%',
            placeholder: bolt.data('omnisearch.placeholder'),
            minimumInputLength: 3,
                url: bolt.conf('paths.async') + 'omnisearch',
                dataType: 'json',
                data: function (params) {
                    console.log('omnisearch: data');
                    return {q: params.term};
                },
                processResults: function (data) {
                    console.log('omnisearch: processResults');
                    var results = [];
                    $.each(data, function (index, item) {
                        results.push({
                            id: item.path,
                    $.each(data, function (index, item) {
                        results.push({
                            id: item.path,
                            path: item.path,
                            text: item.label
                        });
                    });

                    return {results: results};
                }
            },
            templateResult: function (item) {
                var path = item.path ? '<small>' + item.path + '</small>' : '',
                       '</div>';
            },
            templateSelection: function (item) {
                console.log('omnisearch: templateSelection');
                window.location.href = item.path;

                return item.label;
            },
            escapeMarkup: function (m) {
                console.log('omnisearch: escapeMarkup');
                return m;
            }
        });
            }
        });
    };

    // Apply mixin container.
    bolt.omnisearch = omnisearch;

})(Bolt || {}, jQuery, window);

<MSG> Remove debug output
<DFF> @@ -36,12 +36,13 @@
                 url: bolt.conf('paths.async') + 'omnisearch',
                 dataType: 'json',
                 data: function (params) {
-                    console.log('omnisearch: data');
-                    return {q: params.term};
+                    return {
+                        q: params.term
+                    };
                 },
                 processResults: function (data) {
-                    console.log('omnisearch: processResults');
                     var results = [];
+
                     $.each(data, function (index, item) {
                         results.push({
                             id: item.path,
@@ -61,13 +62,11 @@
                        '</div>';
             },
             templateSelection: function (item) {
-                console.log('omnisearch: templateSelection');
                 window.location.href = item.path;
 
                 return item.label;
             },
             escapeMarkup: function (m) {
-                console.log('omnisearch: escapeMarkup');
                 return m;
             }
         });

{'commit': "diff --git a/app/src/js/modules/omnisearch.js b/app/src/js/modules/omnisearch.js\nindex 5095ad8f8..598bdb88b 100644\n--- a/app/src/js/modules/omnisearch.js\n+++ b/app/src/js/modules/omnisearch.js\n@@ -36,12 +36,13 @@\n                 url: bolt.conf('paths.async') + 'omnisearch',\n                 dataType: 'json',\n                 data: function (params) {\n-                    console.log('omnisearch: data');\n-                    return {q: params.term};\n+                    return {\n+                        q: params.term\n+                    };\n                 },\n                 processResults: function (data) {\n-                    console.log('omnisearch: processResults');\n                     var results = [];\n+\n                     $.each(data, function (index, item) {\n                         results.push({\n                             id: item.path,\n@@ -61,13 +62,11 @@\n                        '</div>';\n             },\n             templateSelection: function (item) {\n-                console.log('omnisearch: templateSelection');\n                 window.location.href = item.path;\n \n                 return item.label;\n             },\n             escapeMarkup: function (m) {\n-                console.log('omnisearch: escapeMarkup');\n                 return m;\n             }\n         });\n", 'commit_subject': 'Remove debug output', 'repo_name': 'bolt/bolt', 'committer': {'name': 'rarila', 'email': 'b257af45fbc9f52d0e728490f2c2da9e4f66647e@gmx.net', 'time_sec': '1437180121', 'tz_offset': '120', 'date': {'seconds': '1437180121'}}, 'commit_tree': '5f575b288237fdf6f8e485d4252ccaf92392683e', 'commit_message': 'Remove debug output', 'language_name': 'Shell', 'license': 'mit', 'hunks': "@@ -36,12 +36,13 @@\n                 url: bolt.conf('paths.async') + 'omnisearch',\n                 dataType: 'json',\n                 data: function (params) {\n-                    console.log('omnisearch: data');\n-                    return {q: params.term};\n+                    return {\n+                        q: params.term\n+                    };\n                 },\n                 processResults: function (data) {\n-                    console.log('omnisearch: processResults');\n                     var results = [];\n+\n                     $.each(data, function (index, item) {\n                         results.push({\n                             id: item.path,\n@@ -61,13 +62,11 @@\n                        '</div>';\n             },\n             templateSelection: function (item) {\n-                console.log('omnisearch: templateSelection');\n                 window.location.href = item.path;\n \n                 return item.label;\n             },\n             escapeMarkup: function (m) {\n-                console.log('omnisearch: escapeMarkup');\n                 return m;\n             }\n         });\n", 'addition_count': 4, 'deletion_count': 5, 'src_file': 'a/app/src/js/modules/omnisearch.js', 'tgt_file': 'b/app/src/js/modules/omnisearch.js', 'file_extension': '.js', 'before_file': "/**\n * Omnisearch initialisation.\n *\n * @mixin\n * @namespace Bolt.omnisearch\n *\n * @param {Object} bolt - The Bolt module.\n * @param {Object} $ - jQuery.\n * @param {Object} window - Window object.\n */\n(function (bolt, $, window) {\n    'use strict';\n\n    /**\n     * Bolt.omnisearch mixin container.\n     *\n     * @private\n     * @type {Object}\n     */\n    var omnisearch = {};\n\n    /**\n     * Initializes the mixin.\n     *\n     * @static\n     * @function init\n     * @memberof Bolt.omnisearch\n     */\n    omnisearch.init = function () {\n\n        var $select = $('.omnisearch select');\n        $select.select2({\n            width: '100%',\n            placeholder: bolt.data('omnisearch.placeholder'),\n            minimumInputLength: 3,\n                url: bolt.conf('paths.async') + 'omnisearch',\n                dataType: 'json',\n                data: function (params) {\n                    console.log('omnisearch: data');\n                    return {q: params.term};\n                },\n                processResults: function (data) {\n                    console.log('omnisearch: processResults');\n                    var results = [];\n                    $.each(data, function (index, item) {\n                        results.push({\n                            id: item.path,\n                    $.each(data, function (index, item) {\n                        results.push({\n                            id: item.path,\n                            path: item.path,\n                            text: item.label\n                        });\n                    });\n\n                    return {results: results};\n                }\n            },\n            templateResult: function (item) {\n                var path = item.path ? '<small>' + item.path + '</small>' : '',\n                       '</div>';\n            },\n            templateSelection: function (item) {\n                console.log('omnisearch: templateSelection');\n                window.location.href = item.path;\n\n                return item.label;\n            },\n            escapeMarkup: function (m) {\n                console.log('omnisearch: escapeMarkup');\n                return m;\n            }\n        });\n            }\n        });\n    };\n\n    // Apply mixin container.\n    bolt.omnisearch = omnisearch;\n\n})(Bolt || {}, jQuery, window);\n", 'message': 'Remove debug output', 'author_name': 'rarila', 'lang': 'js'}