mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
First stab at Importer for Drupal QA
This commit is contained in:
@ -322,6 +322,12 @@ class ImportScripts::Base
|
||||
def create_categories(results)
|
||||
results.each do |c|
|
||||
params = yield(c)
|
||||
|
||||
# Basic massaging on the category name
|
||||
params[:name] = "Blank" if params[:name].blank?
|
||||
params[:name].strip!
|
||||
params[:name] = params[:name][0..49]
|
||||
|
||||
puts "\t#{params[:name]}"
|
||||
|
||||
# make sure categories don't go more than 2 levels deep
|
||||
|
Reference in New Issue
Block a user