updated controllers with two parameters