fix linting errors that are fixable with --fix in server side code
This commit is contained in:
parent
449e103fc6
commit
af3cb60ce1
13 changed files with 91 additions and 92 deletions
|
@ -11,7 +11,7 @@ export function signS3(req, res) {
|
|||
filename = uuid.v4() + fileExtension,
|
||||
acl = 'public-read',
|
||||
p = policy({
|
||||
acl: acl,
|
||||
acl,
|
||||
secret: process.env.AWS_SECRET_KEY,
|
||||
length: 5000000, // in bytes?
|
||||
bucket: process.env.S3_BUCKET,
|
||||
|
@ -25,4 +25,4 @@ export function signS3(req, res) {
|
|||
'signature': p.signature
|
||||
};
|
||||
return res.json(result);
|
||||
};
|
||||
}
|
||||
|
|
|
@ -47,7 +47,7 @@ function deleteChild(files, parentId, id) {
|
|||
files = files.map((file) => {
|
||||
if (file.id === parentId) {
|
||||
file.children = file.children.filter(child => child !== id);
|
||||
return file
|
||||
return file;
|
||||
}
|
||||
return file;
|
||||
});
|
||||
|
@ -63,7 +63,7 @@ export function deleteFile(req, res) {
|
|||
// project.files.id(req.query.parentId).children = childrenArray.filter(id => id !== req.params.file_id);
|
||||
project.save(innerErr => {
|
||||
res.json(project.files);
|
||||
})
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -84,7 +84,6 @@ export function getProjects(req, res) {
|
|||
// could just move this to client side
|
||||
return res.json([]);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
export function getProjectsForUser(req, res) {
|
||||
|
|
|
@ -74,7 +74,7 @@ export function updatePreferences(req, res) {
|
|||
|
||||
return res.json(user.preferences);
|
||||
});
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
export function resetPasswordInitiate(req, res) {
|
||||
|
|
|
@ -9,7 +9,7 @@ const defaultSketch = `function setup() {
|
|||
}
|
||||
function draw() {
|
||||
background(220);
|
||||
}`
|
||||
}`;
|
||||
|
||||
const defaultHTML =
|
||||
`<!DOCTYPE html>
|
||||
|
@ -24,7 +24,7 @@ const defaultHTML =
|
|||
<script src="sketch.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
`
|
||||
`;
|
||||
const defaultCSS =
|
||||
`html, body {
|
||||
overflow: hidden;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import { Router } from 'express';
|
||||
const router = new Router();
|
||||
import path from 'path';
|
||||
import { renderIndex } from '../views/index'
|
||||
import { renderIndex } from '../views/index';
|
||||
|
||||
// this is intended to be a temporary file
|
||||
// until i figure out isomorphic rendering
|
||||
|
|
|
@ -93,7 +93,7 @@ export function resolveStyles(sketchDoc, files, projectId) {
|
|||
} else {
|
||||
const style = sketchDoc.createElement('style');
|
||||
style.innerHTML = `\n${resolvedFile.content}`;
|
||||
sketchDoc.getElementsByTagName("head")[0].appendChild(style);
|
||||
sketchDoc.getElementsByTagName('head')[0].appendChild(style);
|
||||
css.parentNode.removeChild(css);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue