File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -233,7 +233,7 @@ function listMyNotes (req, res) {
233
233
}
234
234
235
235
const deleteNote = async ( req , res ) => {
236
- if ( req . isAuthenticated ( ) ) {
236
+ if ( req . isAuthenticated ( ) ) {
237
237
const noteId = await Note . parseNoteIdAsync ( req . params . noteId )
238
238
try {
239
239
const destroyed = await Note . destroy ( {
@@ -260,21 +260,21 @@ const deleteNote = async (req, res) => {
260
260
}
261
261
262
262
const updateNote = async ( req , res ) => {
263
- if ( req . isAuthenticated ( ) ) {
263
+ if ( req . isAuthenticated ( ) ) {
264
264
const noteId = await Note . parseNoteIdAsync ( req . params . noteId )
265
265
try {
266
266
const note = await Note . findOne ( {
267
267
where : {
268
- id : noteId ,
268
+ id : noteId
269
269
}
270
270
} )
271
271
if ( ! note ) {
272
272
logger . error ( 'Update note failed: Can\'t find the note.' )
273
273
return errorNotFound ( req , res )
274
274
}
275
-
275
+
276
276
const updated = await note . update ( {
277
- content : req . body . content ,
277
+ content : req . body . content
278
278
} )
279
279
if ( ! updated ) {
280
280
logger . error ( 'Update note failed: Write data error.' )
Original file line number Diff line number Diff line change @@ -516,7 +516,7 @@ export function finishView (view) {
516
516
$value . unwrap ( )
517
517
try {
518
518
const data = transform ( content )
519
- $elem . html ( ` <div class="markmap-container"><svg></svg></div>` )
519
+ $elem . html ( ' <div class="markmap-container"><svg></svg></div>' )
520
520
markmap ( $elem . find ( 'svg' ) [ 0 ] , data , {
521
521
duration : 0
522
522
} )
You can’t perform that action at this time.
0 commit comments