bugfix from last edit