Merge pull request #2563 from opf/fix/help_auto_loader

prefix representers to help the rails autoloader
pull/2614/head
ulferts 10 years ago
commit e984eebbd4
  1. 4
      lib/api/v3/users/users_api.rb
  2. 4
      lib/api/v3/work_packages/work_packages_api.rb

@ -37,7 +37,7 @@ module API
# Show updated user # Show updated user
status 200 status 200
UserRepresenter.new(@user, current_user: current_user) Users::UserRepresenter.new(@user, current_user: current_user)
else else
fail ::API::Errors::InvalidUserStatusTransition fail ::API::Errors::InvalidUserStatusTransition
end end
@ -56,7 +56,7 @@ module API
end end
get do get do
UserRepresenter.new(@user, current_user: current_user) Users::UserRepresenter.new(@user, current_user: current_user)
end end
delete do delete do

@ -78,8 +78,8 @@ module API
before do before do
@work_package = WorkPackage.find(params[:id]) @work_package = WorkPackage.find(params[:id])
@representer = WorkPackageRepresenter.new(work_package, @representer = WorkPackages::WorkPackageRepresenter.new(work_package,
current_user: current_user) current_user: current_user)
end end
get do get do

Loading…
Cancel
Save