Changed local var to class property