bugfixing constraints