Skip to content

Commit

Permalink
Use const instead of var for added code
Browse files Browse the repository at this point in the history
  • Loading branch information
wwelling committed Jul 8, 2024
1 parent 2809f72 commit 9813421
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/controllers/notificationController.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ app.controller('NotificationController', function ($controller, $scope, $timeout

$scope.forms = {};

var emptyNotification = {
const emptyNotification = {
name: '',
body: '',
active: false,
Expand Down
6 changes: 3 additions & 3 deletions tests/unit/controllers/notificationControllerTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ describe('controller: NotificationController', function () {

describe('Are the scope methods working as expected', function () {
it('resetNotifications should reset notifications', function () {
var notification = new Notification();
const notification = new Notification();
scope.notificationData = notification;
scope.closeModal = function() {};

Expand All @@ -97,7 +97,7 @@ describe('controller: NotificationController', function () {
expect(notification.clearValidationResults).toHaveBeenCalled();
});
it('createNotification should create a notification', function () {
var notification = new Notification();
const notification = new Notification();
notification.title = "New Notification";
scope.notificationData = notification;

Expand All @@ -123,7 +123,7 @@ describe('controller: NotificationController', function () {
});

it('updateNotification should update a notification', function () {
var notification = new Notification();
const notification = new Notification();
var deferred;
notification.mock(mockNotification1);

Expand Down

0 comments on commit 9813421

Please sign in to comment.