From 43a7649d4452f0b1835c030cd23e4e4a374b0fc6 Mon Sep 17 00:00:00 2001 From: James Seymour-Lock Date: Sat, 23 Jan 2016 17:14:12 +0000 Subject: [PATCH] Always show current year in copyright text on "About" page no issue - add `copyrightYear` CP to about page controller - displays the current year in the copyright notice --- ghost/admin/app/controllers/about.js | 12 ++++++++++-- ghost/admin/app/templates/about.hbs | 2 +- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/ghost/admin/app/controllers/about.js b/ghost/admin/app/controllers/about.js index b29839e5a7..5f6c869462 100644 --- a/ghost/admin/app/controllers/about.js +++ b/ghost/admin/app/controllers/about.js @@ -1,6 +1,9 @@ import Ember from 'ember'; -const {Controller} = Ember; +const { + Controller, + computed +} = Ember; export default Controller.extend({ updateNotificationCount: 0, @@ -9,5 +12,10 @@ export default Controller.extend({ updateNotificationChange(count) { this.set('updateNotificationCount', count); } - } + }, + + copyrightYear: computed(function () { + let date = new Date(); + return date.getFullYear(); + }) }); diff --git a/ghost/admin/app/templates/about.hbs b/ghost/admin/app/templates/about.hbs index 4169bfbd80..02c0c2367f 100644 --- a/ghost/admin/app/templates/about.hbs +++ b/ghost/admin/app/templates/about.hbs @@ -36,7 +36,7 @@