Bug #23428 Bug Fixed

fatal error while trying to save new channel

Version: 4.0.6 Reporter: Büro Ballmann Weber

this happened when I tried to save a new channel called “Ausstellungen (Index)”:

Fatal error: Uncaught TypeError: Argument 1 passed to EllisLab\ExpressionEngine\Model\Channel\Channel::duplicatePreferences() must be an instance of EllisLab\ExpressionEngine\Model\Channel\Channel, null given, called in /html/kunstverein/kvh18-004-ee4-structure/system/ee/EllisLab/ExpressionEngine/Controller/Channels/Channels.php on line 1428 and defined in /html/kunstverein/kvh18-004-ee4-structure/system/ee/EllisLab/ExpressionEngine/Model/Channel/Channel.php:292 Stack trace: #0 /html/kunstverein/kvh18-004-ee4-structure/system/ee/EllisLab/ExpressionEngine/Controller/Channels/Channels.php(1428): EllisLab\ExpressionEngine\Model\Channel\Channel->duplicatePreferences(NULL) #1 /html/kunstverein/kvh18-004-ee4-structure/system/ee/EllisLab/ExpressionEngine/Controller/Channels/Channels.php(255): EllisLab\ExpressionEngine\Controller\Channels\Channels->saveChannel(Object(EllisLab\ExpressionEngine\Model\Channel\Channel)) #2 /html/kunstverein/kvh18-004-ee4-structure/system/ee/EllisLab/ExpressionEngine/Controller/Channels/Channels.php(1 in /html/kunstverein/kvh18-004-ee4-structure/system/ee/EllisLab/ExpressionEngine/Model/Channel/Channel.php on line 292

  • Open system/ee/EllisLab/ExpressionEngine/Controller/Channels/Channels.php and find this code on line 1423:

    if ($dupe_id !== FALSE AND is_numeric($dupe_id))

    And REPLACE it with this:

    if ( ! empty($dupe_id) && is_numeric($dupe_id))
.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases