small changes to rest controller