Use consistent function declaration style

This commit is contained in:
Ray Schamp 2016-10-24 11:49:34 -04:00
parent 9f0c4eb098
commit 04d7f4f019
4 changed files with 12 additions and 4 deletions

View file

@ -35,7 +35,7 @@ var domToBlocks = function (blocksDOM) {
* @param {Object} e `Blockly.events.create`
* @return {Array.<Object>} List of blocks from this CREATE event.
*/
module.exports = function (e) {
var adapter = function (e) {
// Validate input
if (typeof e !== 'object') return;
if (typeof e.xml !== 'object') return;
@ -146,3 +146,5 @@ var domToBlock = function (blockDOM, blocks, isTopBlock, parent) {
}
}
};
module.exports = adapter;

View file

@ -8,7 +8,9 @@
* @param {Array} contents Contents of the list, as an array.
* @constructor
*/
module.exports = function List (name, contents) {
var List = function (name, contents) {
this.name = name;
this.contents = contents;
};
module.exports = List;

View file

@ -27,7 +27,7 @@ var mutatorTagToObject = function (dom) {
* @param {(Object|string)} mutation Mutation XML string or DOM.
* @return {Object} Object representing the mutation.
*/
module.exports = function (mutation) {
var mutationAdpater = function (mutation) {
var mutationParsed;
// Check if the mutation is already parsed; if not, parse it.
if (typeof mutation === 'object') {
@ -37,3 +37,5 @@ module.exports = function (mutation) {
}
return mutatorTagToObject(mutationParsed);
};
module.exports = mutationAdpater;

View file

@ -9,8 +9,10 @@
* @param {boolean} isCloud Whether the variable is stored in the cloud.
* @constructor
*/
module.exports = function Variable (name, value, isCloud) {
var Variable = function (name, value, isCloud) {
this.name = name;
this.value = value;
this.isCloud = isCloud;
};
module.exports = Variable;