Updated the constraints code.