fixed bug in calling $this->is_writable()