In my project I have implemented activeadmin gem, which is integrated with devise invitable. So in my application admin can invite a customer through an email. While inviting, i'm getting the following error:
*ActiveRecord::StatementInvalid in Admin::CustomersController#send_invitation
Mysql2::Error: Unknown column 'invitations_count' in 'field list': UPDATE `admin_users` SET `invitations_count` = COALESCE(`invitations_count`, 0) + 1 WHERE `admin_users`.`id` = 1*
This issue has happened after updating the gem devise_invitable to version 1.3.3
To fix it just create a migration
That should add invitations_count field to the table admin_users
For others who has got the same problem but in another table. Here is a migration for a general table users
Such issue could be caught by rspec