Cleaned up the way notifications are created