implemented Mark's feedback