Refactor Notification.php