applied Nick's feedback