Improve get_time script