• Resolved nathaniel7sg

    (@nathaniel7sg)


    Fatal error: Unparenthesized a ? b : c ? d : e is not supported. Use either (a ? b : c) ? d : e or a ? b : (c ? d : e) in {my domain}/public_html/wp-content/plugins/dokan-order-approval/includes/class-plugin-review-request.php on line 311

    My server runs PHP 8

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Sarankumar

    (@sarankumar)

    Hello @nathaniel7sg
    I don’t have PHP 8 to test.
    Goto same line of code at 311 ,/dokan-order-approval/includes/class-plugin-review-request.php
    you can see the following code

    return ! isset( $code ) ? $triggers[ $group ] : isset( $triggers[ $group ]['triggers'][ $code ] ) ? $triggers[ $group ]['triggers'][ $code ] : false;

    replace that code with this

    return (! isset( $code ) ? $triggers[ $group ] : isset( $triggers[ $group ]['triggers'][ $code ] )) ? $triggers[ $group ]['triggers'][ $code ] : false;

    check whether fatal error disappeared . update status here. so that I can give an update.

    • This reply was modified 2 years, 11 months ago by Sarankumar.
    • This reply was modified 2 years, 11 months ago by Sarankumar.
    Thread Starter nathaniel7sg

    (@nathaniel7sg)

    That worked!

    Thread Starter nathaniel7sg

    (@nathaniel7sg)

    Also, when I use the Conditional Shipping and Payments plugin, I am not able to restrict just this payment method. When I restrict this payment method all other payment gateways are also gone. I need to restrict this payment method to only one user role.

    I use a B2B plugin that adds a user role B2B for wholesale buyers.

    Currently, I am using a snippet to deactivate the plugin for ‘customer’ user role so that they can make the payment directly. But I want B2B users to make payment only with approval, but since the plugin is activated for ‘vendor’ user role, they too will need to get approvals for purchase which is not I want….

    So, is it possible to make this compatible with the Conditional Shipping and Payments plugin?

    Plugin Author Sarankumar

    (@sarankumar)

    @nathaniel7sg

    Thank you for your update. we can fix this issue on next update.

    Regarding deactivating the payment gateway just change a priority high/low depending on your requirement. It will work.

    Don’t forget to review the if you found it helpful.

    Thread Starter nathaniel7sg

    (@nathaniel7sg)

    Didn’t get the thing about priority, will changing the priority of the plugin make it work with Conditional Shipping and Payments plugin?

    Plugin Author Sarankumar

    (@sarankumar)

    @nathaniel7sg

    released fix on 1.0.4 version. Closing the tickets. If you have any issues facing please create a separate thread.

    Your reviews matter to us. So please spend few minutes writing a review and give us some motivation to maintain this plugin.

    Thanks

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Error’ is closed to new replies.