Add rubocop to our build. (#5004)

This commit is contained in:
Guo Xiang Tan
2017-07-28 10:20:09 +09:00
committed by GitHub
parent ff4e295c4f
commit 5012d46cbd
871 changed files with 5480 additions and 6056 deletions

View File

@ -47,7 +47,7 @@ class ImportScripts::VBulletin < ImportScripts::Base
database: DB_NAME
)
rescue Exception => e
puts '='*50
puts '=' * 50
puts e.message
puts <<EOM
Cannot connect in to database.
@ -71,7 +71,6 @@ EOM
exit
end
def execute
mysql_query("CREATE INDEX firstpostid_index ON #{TABLE_PREFIX}thread (firstpostid)") rescue nil
@ -422,7 +421,6 @@ EOM
puts sql
end
def import_private_messages
puts "", "importing private messages..."
@ -536,7 +534,6 @@ EOM
end
end
def import_attachments
puts '', 'importing attachments...'
@ -574,7 +571,7 @@ EOM
end
if new_raw != post.raw
PostRevisor.new(post).revise!(post.user, { raw: new_raw }, { bypass_bump: true, edit_reason: 'Import attachments from vBulletin' })
PostRevisor.new(post).revise!(post.user, { raw: new_raw }, bypass_bump: true, edit_reason: 'Import attachments from vBulletin')
end
success_count += 1
@ -828,7 +825,6 @@ EOM
raw
end
def create_permalink_file
puts '', 'Creating Permalink File...', ''
@ -858,7 +854,6 @@ EOM
end
def suspend_users
puts '', "updating banned users"