Changed the logic a little bit :-)