added req.method to check