backdrop-contrib / examples

Examples for Developers
GNU General Public License v2.0
7 stars 9 forks source link

Remove the call to node_type_set_defaults() done right before calling node_type_save() #88

Closed avpaderno closed 6 months ago

avpaderno commented 6 months ago

Some functions call node_type_set_defaults() right before calling node_type_save(), but that is not necessary, since node_type_set_defaults() is the first function node_type_save() calls.

$type = node_type_set_defaults($info);
$type_data = (array) $type;
$type_data['has_title'] = (bool) $type_data['has_title'];
$type_data['modified'] = (bool) $type_data['modified'];
$type_data['disabled'] = (bool) $type_data['disabled'];
avpaderno commented 6 months ago

This issue is the equivalent of https://github.com/backdrop/backdrop-issues/issues/6413 for Backdrop core.