adds bool return value to write method