@@ 514-522 (lines=9) @@ | ||
511 | if( ! $generator_object ){ |
|
512 | continue; |
|
513 | } |
|
514 | if( ! $generator_object instanceof EE_Restriction_Generator_Base ){ |
|
515 | throw new EE_Error( |
|
516 | sprintf( |
|
517 | __( 'Index "%1$s" in the model %2$s\'s _cap_restriction_generators is not a child of EE_Restriction_Generator_Base. It should be that or NULL.', 'event_espresso' ), |
|
518 | $context, |
|
519 | $this->get_this_model_name() |
|
520 | ) |
|
521 | ); |
|
522 | } |
|
523 | $action = $this->cap_action_for_context( $context ); |
|
524 | if( ! $generator_object->construction_finalized() ){ |
|
525 | $generator_object->_construct_finalize( $this, $action ); |
|
@@ 2240-2242 (lines=3) @@ | ||
2237 | $field_with_model_name = $field; |
|
2238 | } |
|
2239 | } |
|
2240 | if( !isset($field_with_model_name) || !$field_with_model_name ){ |
|
2241 | throw new EE_Error(sprintf(__("There is no EE_Any_Foreign_Model_Name field on model %s", "event_espresso"), $this->get_this_model_name() )); |
|
2242 | } |
|
2243 | return $field_with_model_name; |
|
2244 | } |
|
2245 | ||
@@ 4021-4023 (lines=3) @@ | ||
4018 | } |
|
4019 | } |
|
4020 | $classInstance = $this->instantiate_class_from_array_or_object($row); |
|
4021 | if( ! $classInstance ) { |
|
4022 | throw new EE_Error( |
|
4023 | sprintf( |
|
4024 | __( 'Could not create instance of class %s from row %s', 'event_espresso' ), |
|
4025 | $this->get_this_model_name(), |
|
4026 | http_build_query( $row ) |