Fix for ActiveRecord errors in dronehub - REVIEW BEFORE SUBMIT