bugfix, missing endif