Remove datafixup that broke all the things

Test Plan:
Migrations run

Change-Id: I291e0c9ee6e91877f108b3f31f166dad2e3788ea
Reviewed-on: https://gerrit.instructure.com/112912
Reviewed-by: Rob Orton <rob@instructure.com>
Tested-by: Jenkins
QA-Review: August Thornton <august@instructure.com>
Product-Review: Weston Dransfield <wdransfield@instructure.com>
This commit is contained in:
wdransfield 2017-05-23 17:03:26 -06:00 committed by Weston Dransfield
parent 9117e20a05
commit e0ff8a8cf9
2 changed files with 0 additions and 27 deletions

View File

@ -18,7 +18,6 @@
class ChangeLtiResouceHandlerLookupIdNotNull < ActiveRecord::Migration[4.2] class ChangeLtiResouceHandlerLookupIdNotNull < ActiveRecord::Migration[4.2]
tag :postdeploy tag :postdeploy
def change def change
DataFixup::AddLookupToResourceHandlers.run
change_column_null :lti_resource_handlers, :lookup_id, false change_column_null :lti_resource_handlers, :lookup_id, false
end end
end end

View File

@ -1,26 +0,0 @@
#
# Copyright (C) 2017 - present Instructure, Inc.
#
# This file is part of Canvas.
#
# Canvas is free software: you can redistribute it and/or modify it under
# the terms of the GNU Affero General Public License as published by the Free
# Software Foundation, version 3 of the License.
#
# Canvas is distributed in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
# A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
# details.
#
# You should have received a copy of the GNU Affero General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
module DataFixup
module AddLookupToResourceHandlers
def self.run
Lti::ResourceHandler.where(lookup_id: nil).find_each do |rh|
rh.update_attributes(lookup_id: Lti::ResourceHandler.generate_lookup_id_for(rh))
end
end
end
end