Commit f34c90d072a552828308043ce82dc5811767dcf1

Authored by AntonioTerceiro
1 parent 8fdf6ddf

ActionItem154: pointing to the right URL in development environment


git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@1256 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing 1 changed file with 3 additions and 1 deletions   Show diff stats
app/models/profile.rb
... ... @@ -173,7 +173,9 @@ class Profile < ActiveRecord::Base
173 173  
174 174 include ActionController::UrlWriter
175 175 def url
176   - url_for(:host => self.environment.default_hostname, :profile => self.identifier, :controller => 'content_viewer', :action => 'view_page', :page => [])
  176 + options = { :host => self.environment.default_hostname, :profile => self.identifier, :controller => 'content_viewer', :action => 'view_page', :page => [] }
  177 + options.merge!(:port => 3000) if ENV['RAILS_ENV'] == 'development'
  178 + url_for(options)
177 179 end
178 180  
179 181 end
... ...