use instance variable instead of local