fix code to comply with standards