now is thread safe