correcting bug of the undefined  variable while not finding associated constructor of a Controller instance