changed caps logic