ensure safe access