Removed unused 'time' variable which caused trouble with Controller