diff --git a/app/models/services/twitter.rb b/app/models/services/twitter.rb index aeecf8c0c..e7f91e6ec 100644 --- a/app/models/services/twitter.rb +++ b/app/models/services/twitter.rb @@ -1,6 +1,6 @@ class Services::Twitter < Service MAX_CHARACTERS = 140 - +url def post(post, url='') Rails.logger.debug("event=post_to_service type=twitter sender_id=#{self.user_id}") message = public_message(post, url) diff --git a/app/models/user.rb b/app/models/user.rb index e2fac1364..cb4758157 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -5,11 +5,11 @@ require File.join(Rails.root, 'lib/diaspora/user') require File.join(Rails.root, 'lib/salmon/salmon') require 'rest-client' + class User include MongoMapper::Document include Diaspora::UserModules include Encryptor::Private - include ActionView::Helpers::TextHelper plugin MongoMapper::Devise diff --git a/lib/tasks/migration.rb b/lib/tasks/migration.rb new file mode 100644 index 000000000..a79c32741 --- /dev/null +++ b/lib/tasks/migration.rb @@ -0,0 +1,21 @@ +namespace :migration do + desc 'make old registered services into the new class specific services' + task :service_reclassify do + Service.all.each do |s| + provider = s.provider + s._type = "Services::#{provider.camelize}" + s.save + end + end + + desc 'allow to upgrade old image urls to use rel path' + task :swtich_image_urls do + + + + end + + desc 'move all posts and photos to new schema' + task :migrate_status_message_to_posts do + end +end