Topic: Direct Invoice not processing

Recently upgraded my OS which included PHP 8.2.26 and now when I try to place invoice I get an error
"strtolower(): Passing null to parameter #1 ($string) of type string is deprecated in file: /var/www/html/companyname/includes/ui/ui_lists.inc at line 305".
After searching I upgraded FA from 2.4.10 to 2.4.18 which seems to have been succesfull. It shows the correct version number when I log in but my problem with invoicing remains. Nothing happens until I click a second time on the place invoice button, then where I used to get a menu to view or print invoice I get sales order menu with same options but view order is blank.
When running debug mode using parameter "2", I get 5 errors as soon as I click Direct Invoice --- all beginning with the same line 305 error as above.
I have only ever used Direct Invoice method.
Any help is appreciated.

Re: Direct Invoice not processing

Looks like the way NULL is checked in the next line.
Try the next line:

if ($type != NULL) {

as

if ($type != NULL || $type != '') {

Also check if it runs okay with PHP 7.x.

Re: Direct Invoice not processing

@apmuthu Thanks for the response.
The issue was when I copied the new FA files to overwrite my older version they were not in fact overwritten.
The older version files were still being accessed which of course brought about the errors.
So I copied the new files again using rsync,restored my backed up database, and then followed the instructions in the system diagnosis tab.
Logged out and back in.
Everything works again.
Once again, Thanks for all the work you guys put into this project.

Re: Direct Invoice not processing

@apmuthu Thanks for the response.
The issue was when I copied the new FA files to overwrite my older version they were not in fact overwritten.
The older version files were still being accessed which of course brought about the errors.
So I copied the new files again using rsync,restored my backed up database, and then followed the instructions in the system diagnosis tab.
Logged out and back in.
Everything works again.
Once again, Thanks for all the work you guys put into this project.


@bookworm Glad to hear you got it sorted out! This is a good reminder to double-check that files are properly overwritten when upgrading. For anyone facing similar issues, verifying the active file versions and clearing any potential opcode caches (like APCu or OPcache) might also help.

Thanks for sharing your solution!