Added error handling for missing timer