refractoring
added 404 message for not found