Fixed MySQL error when unsubscribing from watch emails

DragonByte Tech

Well-known member
Affected version
2.2.5
While assisting on another website, I came across this MySQL error
Code:
XF\Db\Exception: MySQL query error [1366]: Incorrect integer value: '' for column 'email_subscribe' at row 1 src/XF/Db/AbstractStatement.php:230

I believe the offending code is this bit in src/addons/XFRM/EmailStop/ResourceItem.php:41
PHP:
$resourceWatchRepo->setWatchState($resource, $user, 'update', ['email_subscribe' => false]);

Should be ['email_subscribe' => 0] in order to not trigger the error.
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XFRM release (2.3.0 Release Candidate 5).

Change log:
Fix MySQL error when unsubscribing from watched resources
There may be a delay before changes are rolled out to the XenForo Community.
 


Write your reply...
Back
Top Bottom