private static function areDimensionsEqualAndNotNull($lhs, $rhs) { return !empty($lhs) && !empty($rhs) && $lhs->getId() == $rhs->getId(); }