fixed routes when no entities exist.

Signed-off-by: Tom Green <kingofcuddles@gmail.com>