From 0fb53b61c4e0d4c1f8da20a212c680741ff93866 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rodrigo=20Guimara=CC=83es?= Date: Thu, 4 Feb 2021 23:42:07 -0300 Subject: [PATCH] fix identations --- .../repositories/class-tainacan-collections.php | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/classes/repositories/class-tainacan-collections.php b/src/classes/repositories/class-tainacan-collections.php index 1db6b3cf1..632ffb18e 100644 --- a/src/classes/repositories/class-tainacan-collections.php +++ b/src/classes/repositories/class-tainacan-collections.php @@ -26,7 +26,7 @@ class Collections extends Repository { * {@inheritDoc} * @see \Tainacan\Repositories\Repository::get_map() */ - protected function _get_map() { + protected function _get_map() { return apply_filters( 'tainacan-get-map-' . $this->get_name(), [ 'name' => [ 'map' => 'post_title', @@ -303,10 +303,9 @@ class Collections extends Repository { * @see \Tainacan\Repositories\Repository::insert() */ public function insert( $collection ) { + $this->pre_process( $collection ); + $this->handle_parent_order_clone( $collection ); - $this->pre_process( $collection ); - - $this->handle_parent_order_clone( $collection ); $new_collection = parent::insert( $collection ); $this->handle_core_metadata( $new_collection ); @@ -389,12 +388,9 @@ class Collections extends Repository { } function pre_process( $collection ) { - $this->old_collection = $this->fetch( $collection->get_id() ); $this->old_core_title = $collection->get_core_title_metadatum(); $this->old_core_description = $collection->get_core_description_metadatum(); - - } function handle_core_metadata( $collection ) {