changed ApplicationController to instance of Controller