always return JSON result from SleepController, fix example code