replace deprecated express methods