From d4de345e87db1c03da404a5d1ab3fced81e8edf6 Mon Sep 17 00:00:00 2001 From: pichalite Date: Fri, 7 Apr 2017 21:39:22 +0000 Subject: [PATCH] syntax --- src/controllers/accounts/edit.js | 37 +++++++++++++++++++------------- src/controllers/index.js | 15 +++++++------ 2 files changed, 31 insertions(+), 21 deletions(-) diff --git a/src/controllers/accounts/edit.js b/src/controllers/accounts/edit.js index 71cf7717c8..d659b0153f 100644 --- a/src/controllers/accounts/edit.js +++ b/src/controllers/accounts/edit.js @@ -36,12 +36,15 @@ editController.get = function (req, res, callback) { }); userData.title = '[[pages:account/edit, ' + userData.username + ']]'; - userData.breadcrumbs = helpers.buildBreadcrumbs([{ - text: userData.username, - url: '/user/' + userData.userslug, - }, { - text: '[[user:edit]]', - }]); + userData.breadcrumbs = helpers.buildBreadcrumbs([ + { + text: userData.username, + url: '/user/' + userData.userslug, + }, + { + text: '[[user:edit]]', + }, + ]); userData.editButtons = []; plugins.fireHook('filter:user.account.edit', userData, function (err, userData) { @@ -81,15 +84,19 @@ function renderRoute(name, req, res, next) { } userData.title = '[[pages:account/edit/' + name + ', ' + userData.username + ']]'; - userData.breadcrumbs = helpers.buildBreadcrumbs([{ - text: userData.username, - url: '/user/' + userData.userslug, - }, { - text: '[[user:edit]]', - url: '/user/' + userData.userslug + '/edit', - }, { - text: '[[user:' + name + ']]', - }]); + userData.breadcrumbs = helpers.buildBreadcrumbs([ + { + text: userData.username, + url: '/user/' + userData.userslug, + }, + { + text: '[[user:edit]]', + url: '/user/' + userData.userslug + '/edit', + }, + { + text: '[[user:' + name + ']]', + }, + ]); res.render('account/edit/' + name, userData); }); diff --git a/src/controllers/index.js b/src/controllers/index.js index ac7c514d83..6cebf29d8f 100644 --- a/src/controllers/index.js +++ b/src/controllers/index.js @@ -89,12 +89,15 @@ Controllers.reset = function (req, res, next) { displayExpiryNotice: req.session.passwordExpired, code: req.params.code, minimumPasswordLength: parseInt(meta.config.minimumPasswordLength, 10), - breadcrumbs: helpers.buildBreadcrumbs([{ - text: '[[reset_password:reset_password]]', - url: '/reset', - }, { - text: '[[reset_password:update_password]]', - }]), + breadcrumbs: helpers.buildBreadcrumbs([ + { + text: '[[reset_password:reset_password]]', + url: '/reset', + }, + { + text: '[[reset_password:update_password]]', + }, + ]), title: '[[pages:reset]]', });