Refactor: immutable var -> mutable val