Trying to figure out why I'm getting this error while adding new page attributes to a package. Everything works fine if I uninstall then reinstall the package, but I get this error if I try to upgrade it:
Fatal error: Call to a member function getAttributeTypeID() on a non-object in /Users/justrjlewis/RJLewisDesign/Sites/development(Themes)/updates/concrete5.6.3.1_updater/concrete/core/models/attribute/key.php on line 250
Everything works fine, but the attribute does not get added.
In the install method, the package doesn't exist and is created by:
$pkg=parent::install();
In the upgrade method,
parent::upgrade();
doesn't return anything because the package object already exists as $this, so if you replace $pkg in your code with $this, that should solve the problem.
This website stores cookies on your computer. These cookies are used to improve
your website experience and provide more personalized services to you, both on this website and through
other media. To find out more about the cookies we use, see our Privacy Policy.
In the upgrade method,
doesn't return anything because the package object already exists as $this, so if you replace $pkg in your code with $this, that should solve the problem.