updated users controller to use $this variable