From 282b73d980d24dd679a220bede1d76b677879326 Mon Sep 17 00:00:00 2001
From: Marcela Ribeiro de Oliveira <mro15@inf.ufpr.br>
Date: Wed, 25 Jan 2017 10:13:51 -0200
Subject: [PATCH] authorize collection

---
 app/controllers/v1/collections_controller.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/controllers/v1/collections_controller.rb b/app/controllers/v1/collections_controller.rb
index 0e0727c0..9a749649 100644
--- a/app/controllers/v1/collections_controller.rb
+++ b/app/controllers/v1/collections_controller.rb
@@ -8,7 +8,7 @@ class V1::CollectionsController < ApplicationController
   include ::SubjectableController
   include ::StageableController
 
-  before_action :authenticate_user!, only: [:create, :update, :destroy]
+  before_action :authenticate_user!, except: [:create, :index, :show]
   before_action :set_collection, only: [:show, :update, :destroy, :add_object, :delete_object]
   before_action :set_new_collection, only: :index
   before_action :authorize!, except: [:create, :tagging, :untagging, :subjecting, :unsubjecting, :add_stages, :remove_stages]
-- 
GitLab