mirror of
https://github.com/taobataoma/meanTorrent.git
synced 2026-07-19 11:39:55 +02:00
Merge pull request #381 from treyhunner/fix-editorconfig
Fix .editorconfig file
This commit is contained in:
@@ -1,36 +1,25 @@
|
||||
# EditorConfig is awesome: http://EditorConfig.org
|
||||
|
||||
# Howto with your editor:
|
||||
# Sublime: https://github.com/sindresorhus/editorconfig-sublime
|
||||
# How-to with your editor: http://editorconfig.org/#download
|
||||
|
||||
# top-most EditorConfig file
|
||||
root = true
|
||||
|
||||
# Unix-style newlines with a newline ending every file
|
||||
[**]
|
||||
[*]
|
||||
end_of_line = lf
|
||||
indent_style = tab
|
||||
insert_final_newline = true
|
||||
|
||||
# Standard at: https://github.com/felixge/node-style-guide
|
||||
[**.js, **.json]
|
||||
[{Dockerfile,Procfile}]
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
# Standard at: https://github.com/felixge/node-style-guide
|
||||
[{*.js,*.json}]
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
quote_type = single
|
||||
curly_bracket_next_line = false
|
||||
spaces_around_operators = true
|
||||
space_after_control_statements = true
|
||||
space_after_anonymous_functions = false
|
||||
spaces_in_brackets = false
|
||||
|
||||
# No Standard. Please document a standard if different from .js
|
||||
[**.yml, **.html, **.css]
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
# No standard. Please document a standard if different from .js
|
||||
[**.md]
|
||||
indent_style = tab
|
||||
|
||||
# Standard at:
|
||||
[Makefile]
|
||||
indent_style = tab
|
||||
@@ -26,4 +26,4 @@ ENV NODE_ENV development
|
||||
# Port 3000 for server
|
||||
# Port 35729 for livereload
|
||||
EXPOSE 3000 35729
|
||||
CMD ["grunt"]
|
||||
CMD ["grunt"]
|
||||
|
||||
@@ -117,4 +117,4 @@ exports.hasAuthorization = function(req, res, next) {
|
||||
});
|
||||
}
|
||||
next();
|
||||
};
|
||||
};
|
||||
|
||||
@@ -8,4 +8,4 @@ exports.index = function(req, res) {
|
||||
user: req.user || null,
|
||||
request: req
|
||||
});
|
||||
};
|
||||
};
|
||||
|
||||
@@ -39,4 +39,4 @@ exports.getErrorMessage = function(err) {
|
||||
}
|
||||
|
||||
return message;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -13,4 +13,4 @@ module.exports = _.extend(
|
||||
require('./users/users.authorization.server.controller'),
|
||||
require('./users/users.password.server.controller'),
|
||||
require('./users/users.profile.server.controller')
|
||||
);
|
||||
);
|
||||
|
||||
@@ -24,7 +24,7 @@ exports.signup = function(req, res) {
|
||||
user.provider = 'local';
|
||||
user.displayName = user.firstName + ' ' + user.lastName;
|
||||
|
||||
// Then save the user
|
||||
// Then save the user
|
||||
user.save(function(err) {
|
||||
if (err) {
|
||||
return res.status(400).send({
|
||||
@@ -203,4 +203,4 @@ exports.removeOAuthProvider = function(req, res, next) {
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
@@ -142,7 +142,7 @@ exports.reset = function(req, res, next) {
|
||||
if (err) {
|
||||
res.status(400).send(err);
|
||||
} else {
|
||||
// Return authenticated user
|
||||
// Return authenticated user
|
||||
res.json(user);
|
||||
|
||||
done(err, user);
|
||||
|
||||
@@ -53,4 +53,4 @@ exports.update = function(req, res) {
|
||||
*/
|
||||
exports.me = function(req, res) {
|
||||
res.json(req.user || null);
|
||||
};
|
||||
};
|
||||
|
||||
@@ -31,4 +31,4 @@ var ArticleSchema = new Schema({
|
||||
}
|
||||
});
|
||||
|
||||
mongoose.model('Article', ArticleSchema);
|
||||
mongoose.model('Article', ArticleSchema);
|
||||
|
||||
@@ -143,4 +143,4 @@ UserSchema.statics.findUniqueUsername = function(username, suffix, callback) {
|
||||
});
|
||||
};
|
||||
|
||||
mongoose.model('User', UserSchema);
|
||||
mongoose.model('User', UserSchema);
|
||||
|
||||
@@ -19,4 +19,4 @@ module.exports = function(app) {
|
||||
|
||||
// Finish by binding the article middleware
|
||||
app.param('articleId', articles.articleByID);
|
||||
};
|
||||
};
|
||||
|
||||
@@ -4,4 +4,4 @@ module.exports = function(app) {
|
||||
// Root routing
|
||||
var core = require('../../app/controllers/core.server.controller');
|
||||
app.route('/').get(core.index);
|
||||
};
|
||||
};
|
||||
|
||||
@@ -54,4 +54,4 @@ module.exports = function(app) {
|
||||
|
||||
// Finish by binding the user middleware
|
||||
app.param('userId', users.userByID);
|
||||
};
|
||||
};
|
||||
|
||||
@@ -116,7 +116,7 @@ describe('Article CRUD tests', function() {
|
||||
.end(function(articleSaveErr, articleSaveRes) {
|
||||
// Set message assertion
|
||||
(articleSaveRes.body.message).should.match('Title cannot be blank');
|
||||
|
||||
|
||||
// Handle article save error
|
||||
done(articleSaveErr);
|
||||
});
|
||||
@@ -250,7 +250,7 @@ describe('Article CRUD tests', function() {
|
||||
});
|
||||
|
||||
it('should not be able to delete an article if not signed in', function(done) {
|
||||
// Set article user
|
||||
// Set article user
|
||||
article.user = user;
|
||||
|
||||
// Create new article model instance
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
<pre>
|
||||
{{url}} is not a valid path.
|
||||
</pre>
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
|
||||
@@ -5,4 +5,4 @@
|
||||
<pre>
|
||||
{{error}}
|
||||
</pre>
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
|
||||
@@ -78,4 +78,4 @@
|
||||
<![endif]-->
|
||||
</body>
|
||||
|
||||
</html>
|
||||
</html>
|
||||
|
||||
@@ -10,4 +10,4 @@
|
||||
<br>
|
||||
<p>The {{appName}} Support Team</p>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
@@ -15,4 +15,4 @@
|
||||
<br>
|
||||
<p>The {{appName}} Support Team</p>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
@@ -11,6 +11,6 @@
|
||||
"angular-bootstrap": "~0.11.2",
|
||||
"angular-bootstrap": "~0.12.0",
|
||||
"angular-ui-utils": "~0.1.1",
|
||||
"angular-ui-router": "~0.2.11"
|
||||
"angular-ui-router": "~0.2.11"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,7 +27,7 @@ module.exports.getGlobbedFiles = function(globPatterns, removeRoot) {
|
||||
// The output array
|
||||
var output = [];
|
||||
|
||||
// If glob pattern is array so we use each pattern in a recursive way, otherwise we use glob
|
||||
// If glob pattern is array so we use each pattern in a recursive way, otherwise we use glob
|
||||
if (_.isArray(globPatterns)) {
|
||||
globPatterns.forEach(function(globPattern) {
|
||||
output = _.union(output, _this.getGlobbedFiles(globPattern, removeRoot));
|
||||
@@ -73,4 +73,4 @@ module.exports.getJavaScriptAssets = function(includeTests) {
|
||||
module.exports.getCSSAssets = function() {
|
||||
var output = this.getGlobbedFiles(this.assets.lib.css.concat(this.assets.css), 'public/');
|
||||
return output;
|
||||
};
|
||||
};
|
||||
|
||||
2
config/env/all.js
vendored
2
config/env/all.js
vendored
@@ -69,4 +69,4 @@ module.exports = {
|
||||
'public/modules/*/tests/*.js'
|
||||
]
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
2
config/env/secure.js
vendored
2
config/env/secure.js
vendored
@@ -71,4 +71,4 @@ module.exports = {
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
2
config/env/test.js
vendored
2
config/env/test.js
vendored
@@ -56,4 +56,4 @@ module.exports = {
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
@@ -28,4 +28,4 @@ module.exports = function() {
|
||||
}
|
||||
});
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
@@ -33,4 +33,4 @@ module.exports = {
|
||||
return options;
|
||||
}
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
@@ -7,7 +7,7 @@ var passport = require('passport'),
|
||||
User = require('mongoose').model('User'),
|
||||
path = require('path'),
|
||||
config = require('./config');
|
||||
|
||||
|
||||
/**
|
||||
* Module init function.
|
||||
*/
|
||||
@@ -30,4 +30,4 @@ module.exports = function() {
|
||||
config.getGlobbedFiles('./config/strategies/**/*.js').forEach(function(strategy) {
|
||||
require(path.resolve(strategy))();
|
||||
});
|
||||
};
|
||||
};
|
||||
|
||||
@@ -38,4 +38,4 @@ module.exports = function() {
|
||||
users.saveOAuthUserProfile(req, providerUserProfile, done);
|
||||
}
|
||||
));
|
||||
};
|
||||
};
|
||||
|
||||
@@ -43,4 +43,4 @@ module.exports = function() {
|
||||
users.saveOAuthUserProfile(req, providerUserProfile, done);
|
||||
}
|
||||
));
|
||||
};
|
||||
};
|
||||
|
||||
@@ -38,4 +38,4 @@ module.exports = function() {
|
||||
users.saveOAuthUserProfile(req, providerUserProfile, done);
|
||||
}
|
||||
));
|
||||
};
|
||||
};
|
||||
|
||||
@@ -39,4 +39,4 @@ module.exports = function() {
|
||||
users.saveOAuthUserProfile(req, providerUserProfile, done);
|
||||
}
|
||||
));
|
||||
};
|
||||
};
|
||||
|
||||
@@ -35,4 +35,4 @@ module.exports = function() {
|
||||
});
|
||||
}
|
||||
));
|
||||
};
|
||||
};
|
||||
|
||||
@@ -42,4 +42,4 @@ module.exports = function() {
|
||||
users.saveOAuthUserProfile(req, providerUserProfile, done);
|
||||
}
|
||||
));
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user