add a readonly mode