closes #9: EActiveRecordRelationBehavior Check is_array before array_key_exists
Fixed bug in exception handling