RangeMachine
-
Posts
9 -
Joined
-
Last visited
Content Type
Downloads
Release Notes
IPS4 Guides
IPS4 Developer Documentation
Invision Community Blog
Development Blog
Deprecation Tracker
Providers Directory
Forums
Events
Store
Gallery
Posts posted by RangeMachine
-
-
After upgrade to IPS 4.6 my customers are not able to purchase/renew/etc any item.
OutOfRangeException: (0) #0 /var/www/censored/applications/nexus/modules/front/checkout/checkout.php(1176): IPS\Patterns\_ActiveRecord::load() #1 /var/www/censored/system/Helpers/Wizard/Wizard.php(181): IPS\nexus\modules\front\checkout\_checkout->_pay() #2 /var/www/censored/applications/nexus/modules/front/checkout/checkout.php(170): IPS\Helpers\_Wizard->__toString() #3 /var/www/censored/system/Dispatcher/Controller.php(101): IPS\nexus\modules\front\checkout\_checkout->manage() #4 /var/www/censored/applications/nexus/modules/front/checkout/checkout.php(57): IPS\Dispatcher\_Controller->execute() #5 /var/www/censored/system/Dispatcher/Dispatcher.php(153): IPS\nexus\modules\front\checkout\_checkout->execute() #6 /var/www/censored/index.php(13): IPS\_Dispatcher->run() #7 {main}
Theres part of code from applications\nexus\modules\front\checkout\checkout.php (line 1171) file:
/* Verify stock level one last time. It's possible someone added an item to their cart, then someone else did and checked out and the stock level is now 0. */ foreach ( $this->invoice->items as $item ) { if( $item->appKey == 'nexus' AND $item->typeKey == 'package' ) { $package = \IPS\nexus\Package::load( $item->id ); $data = $package->optionValuesStockAndPrice( $package->optionValues( $item->details ) ); if ( $data['stock'] != -1 and $data['stock'] < $item->quantity ) { \IPS\Output::i()->error( \IPS\Member::loggedIn()->language()->addToStack( 'not_enough_in_stock_checkout', FALSE, array( 'pluralize' => array( $data['stock'] ), 'sprintf' => array( $item->name ) ) ), '1X196/G', 403, '' ); } } }
From what I can see $package = \IPS\nexus\Package::load( $item->id ); tries to load Package with purchase id, eg \IPS\nexus\Package::load( 672 ) in my case for my profile and of course it fails because theres no package with 672 id. Commenting this code fixes the problem.
I guess it should use package id instead of purchase id, but I personally have no idea how to get package id from invoice.
UPDATE: IPS support confirmed bug and it will be fixed in the next update. -
On 3/14/2021 at 9:45 PM, mark2012 said:
you managed to make the plugin working ?
Running my plugin since I wrote it on my store without problems.
- Haku2, mark2012 and Jordan Miller
- 3
-
On 2/17/2021 at 2:25 PM, SoftwareFactory said:
Seems like Discord drastically increased some of their limits. It will be fixed it in the next update. Thank you for reporting this and sorry for the inconvenience caused by this issue.
No problem and thank you for answer 🙂
-
-
On 1/6/2021 at 9:16 PM, iacas said:
Got this earlier today:
A configuration issue has been detected on your community which requires your attention.
Locked Task: spaciousMembersOnline
One of the routine maintenance tasks which run in the background has failed several times, which may indicate a configuration issue.I'm not giving it a lot of consideration for now.
I have same thing, any solution?
Possible bug in checkout front module (IPS 4.6)
in Technical Problems
Posted
Will do.