remove deprecated code
duration check
duration check