handle invalid heights