add function to disable editing