0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-20 22:42:53 -05:00

Bump grunt-jslint and fix issues

This commit is contained in:
Hannah Wolfe 2013-11-01 12:12:01 +00:00
parent e9eacc454a
commit 0db907ada2
4 changed files with 19 additions and 18 deletions

View file

@ -12,7 +12,7 @@ var Ghost = require('../../ghost'),
db;
db = {
export: function (req, res) {
'export': function (req, res) {
/*jslint unparam:true*/
return dataExport().then(function (exportedData) {
// Save the exported data to the file system for download
@ -38,7 +38,8 @@ db = {
});
});
},
import: function (req, res) {
'import': function (req, res) {
var notification;
if (!req.files.importfile || req.files.importfile.size === 0 || req.files.importfile.name.indexOf('json') === -1) {
/**
@ -49,7 +50,7 @@ db = {
* - If the size is 0
* - If the name doesn't have json in it
*/
var notification = {
notification = {
type: 'error',
message: "Must select a .json file to import",
status: 'persistent',
@ -124,7 +125,7 @@ db = {
});
})
.then(function importSuccess() {
var notification = {
notification = {
type: 'success',
message: "Data imported. Log in with the user details you imported",
status: 'persistent',
@ -141,7 +142,7 @@ db = {
}, function importFailure(error) {
// Notify of an error if it occurs
var notification = {
notification = {
type: 'error',
message: error.message || error,
status: 'persistent',
@ -152,7 +153,7 @@ db = {
res.redirect('/ghost/debug/');
});
});
},
}
};
module.exports.db = db;

View file

@ -122,7 +122,7 @@ frontendControllers = {
title: _.escape(post.title),
guid: post.uuid,
url: siteUrl + '/' + post.slug + '/',
date: post.published_at,
date: post.published_at
},
content = post.html;

View file

@ -23,7 +23,7 @@ var when = require('when'),
updated_at: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true},
published_at: {maxlength: 0, nullable: true},
published_by: {maxlength: 0, nullable: true},
published_by: {maxlength: 0, nullable: true}
},
users: {
id: {maxlength: 0, nullable: false},
@ -46,7 +46,7 @@ var when = require('when'),
created_at: {maxlength: 0, nullable: false},
created_by: {maxlength: 0, nullable: false},
updated_at: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true}
},
roles: {
id: {maxlength: 0, nullable: false},
@ -56,12 +56,12 @@ var when = require('when'),
created_at: {maxlength: 0, nullable: false},
created_by: {maxlength: 0, nullable: false},
updated_at: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true}
},
roles_users: {
id: {maxlength: 0, nullable: false},
role_id: {maxlength: 0, nullable: false},
user_id: {maxlength: 0, nullable: false},
user_id: {maxlength: 0, nullable: false}
},
permissions: {
id: {maxlength: 0, nullable: false},
@ -73,17 +73,17 @@ var when = require('when'),
created_at: {maxlength: 0, nullable: false},
created_by: {maxlength: 0, nullable: false},
updated_at: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true}
},
permissions_users: {
id: {maxlength: 0, nullable: false},
user_id: {maxlength: 0, nullable: false},
permission_id: {maxlength: 0, nullable: false},
permission_id: {maxlength: 0, nullable: false}
},
permissions_roles: {
id: {maxlength: 0, nullable: false},
role_id: {maxlength: 0, nullable: false},
permission_id: {maxlength: 0, nullable: false},
permission_id: {maxlength: 0, nullable: false}
},
settings: {
id: {maxlength: 0, nullable: false},
@ -94,7 +94,7 @@ var when = require('when'),
created_at: {maxlength: 0, nullable: false},
created_by: {maxlength: 0, nullable: false},
updated_at: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true}
},
tags: {
id: {maxlength: 0, nullable: false},
@ -108,12 +108,12 @@ var when = require('when'),
created_at: {maxlength: 0, nullable: false},
created_by: {maxlength: 0, nullable: false},
updated_at: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true},
updated_by: {maxlength: 0, nullable: true}
},
posts_tags: {
id: {maxlength: 0, nullable: false},
post_id: {maxlength: 0, nullable: false},
tag_id: {maxlength: 0, nullable: false},
tag_id: {maxlength: 0, nullable: false}
}
};

View file

@ -66,7 +66,7 @@
"grunt-contrib-watch": "~0.5.3",
"grunt-express-server": "~0.4.2",
"grunt-groc": "~0.3.0",
"grunt-jslint": "~1.0.0",
"grunt-jslint": "~1.1.1",
"grunt-mocha-cli": "~1.0.6",
"grunt-open": "~0.2.2",
"grunt-shell": "~0.3.1",