- Edited
Hi all!
I've maded a plugin for automatically add time to a task while editing tickets.. developed for 1.14 (php 7.x) it works flawlessy also in 1.15.. now I've upgraded both installations to 1.17 and the plugin first block the migration (php8 conversion needed) then it cant be enabled again because it makes somewhat crash in the core..
as you can see from the logs it hangs in the function inside Staff class.. called by getStaffMembers.. There is no parameters to be set so I assume that there are problems with $cfg global var inside staff members.. do I have to initialize somewhat inside plugin code?
PHP Fatal error: Uncaught Error: Call to a member function getAgentNameFormat() on null in /home/ostckt/public_html/include/class.staff.php:1050
Stack trace:
#0 /home/ostckt/public_html/include/class.staff.php(1065): Staff::getsortby()
#1 /home/ostckt/public_html/include/class.staff.php(1004): Staff::nsort()
#2 /home/ostckt/public_html/include/plugins/autotask/config.php(35): Staff::getStaffMembers()
#3 /home/ostckt/public_html/include/class.plugin.php(22): AutoTaskPluginConfig->getOptions()
#4 /home/ostckt/public_html/include/class.plugin.php(1086): PluginConfig->__construct()
#5 /home/ostckt/public_html/include/class.plugin.php(788): PluginInstance->getConfig()
#6 /home/ostckt/public_html/include/class.plugin.php(1161): Plugin->getConfig()
#7 /home/ostckt/public_html/include/class.plugin.php(202): PluginInstance->bootstrap()
#8 /home/ostckt/public_html/include/class.osticket.php(668): PluginManager->bootstrap()
#9 /home/ostckt/public_html/main.inc.php(33): osTicket::start()
#10 /home/ostckt/public_html/scp/staff.inc.php(20): require_once('...')
#11 /home/ostckt/public_html/scp/admin.inc.php(16): require_once('...')
#12 /home/ostckt/public_html/scp/helptopics.php(16): require('...')
#13 {main}
thrown in /home/ostckt/public_html/include/class.staff.php on line 1050, referer: https://support.demoplugin.com/scp/forms.php
Thanks to all