handle try/catch by promise