Switched to mutable rather then ref