hook for constraint checks