[UP] Fixed some bugs.
[AD] Added 'return' statment.