Removed var_dump, fixed some wrong method calls

It should be all working now