small changes to the contorller, familiarizing myself to the api docs