Skip to content

Commit eaaa4f2

Browse files
committed
Revert "Revert "Before and after form hooks order""
This reverts commit 54cfa40.
1 parent 54cfa40 commit eaaa4f2

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

includes/CMB2.php

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -321,18 +321,6 @@ public function render_form_close( $object_id = 0, $object_type = '' ) {
321321

322322
$this->render_hidden_fields();
323323

324-
/**
325-
* Hook after form form has been rendered
326-
*
327-
* @param array $cmb_id The current box ID.
328-
* @param int $object_id The ID of the current object.
329-
* @param string $object_type The type of object you are working with.
330-
* Usually `post` (this applies to all post-types).
331-
* Could also be `comment`, `user` or `options-page`.
332-
* @param array $cmb This CMB2 object.
333-
*/
334-
do_action( 'cmb2_after_form', $this->cmb_id, $object_id, $object_type, $this );
335-
336324
/**
337325
* Hook after form form has been rendered
338326
*
@@ -347,6 +335,18 @@ public function render_form_close( $object_id = 0, $object_type = '' ) {
347335
*/
348336
do_action( "cmb2_after_{$object_type}_form_{$this->cmb_id}", $object_id, $this );
349337

338+
/**
339+
* Hook after form form has been rendered
340+
*
341+
* @param array $cmb_id The current box ID.
342+
* @param int $object_id The ID of the current object.
343+
* @param string $object_type The type of object you are working with.
344+
* Usually `post` (this applies to all post-types).
345+
* Could also be `comment`, `user` or `options-page`.
346+
* @param array $cmb This CMB2 object.
347+
*/
348+
do_action( 'cmb2_after_form', $this->cmb_id, $object_id, $object_type, $this );
349+
350350
echo "\n<!-- End CMB2 Fields -->\n";
351351

352352
}

0 commit comments

Comments
 (0)