Q2A Market - Support

We are here to provide you support for Q2A Market premium and free products. If you have any issue in installation, option settings or any bug you found. Please create a ticket. We would try to get back to you as soon as possible.

Recalc points doesn't work for external user ids which are textual [closed]

Hi

Recalculating points from Admin page does not work for external sso enabled users in q2a when the userids are textual (e.g. VARCHAR). It does the first 10 users it finds and then stops.

The reason is that this code below from qa-app-recalc.php assumes an array of numeric user ids when they are not numeric in this case.

                       case 'dorecalcpoints_recalc':
                            $userids=qa_db_users_get_for_recalc_points($next, 10);
                            if (count($userids)) {
                                    $lastuserid=max($userids);
                                    qa_db_users_recalc_points($next, $lastuserid);
                                    $next=1+$lastuserid;
                                    $done+=count($userids);
                                    $continue=true;
                            } else {
                                    qa_db_truncate_userpoints($next);
                                    qa_db_userpointscount_update(); // quick so just do it here
                                    qa_recalc_transition($state, 'dorecalcpoints_complete');
                            }
                            break;

My workaround is just to increase 10 to 1000, but I have no idea if that's a good idea or not.

closed with the note: Non product or non featured conversation. However kept for record.
opened on Dec 15 in Feature Request
closed Dec 26

OK I get it, you're not Q2A. Very confusing calling yourself Q2A Market.

1 Answer

 
Best answer

This is good catch. However we would not be able to modify the core so that would be great if you can post on the Question2Answer board.

Please share your idea for new themes and plugin features. We would try to implement in our product.

answered Dec 26

What on earth are you talking about? This is a bug in the core product.

I'm sorry but couldn't get you. Is there any bug with our product? Please specifythe product name if it is. Since you had opened ticket under Featured Request, I thought it is some featured request related to the core.