remove print and use error_log