From 027cfdfac140fd5f44dbf952b532b27538e559fe Mon Sep 17 00:00:00 2001 From: HombreLaser Date: Mon, 1 May 2023 11:58:29 -0600 Subject: Añade políticas CORS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/initializers/cors.rb | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'config') diff --git a/config/initializers/cors.rb b/config/initializers/cors.rb index 0763c0c..bb5216b 100644 --- a/config/initializers/cors.rb +++ b/config/initializers/cors.rb @@ -8,10 +8,8 @@ Rails.application.config.middleware.insert_before 0, Rack::Cors do allow do - origins 'localhost:3000', '127.0.0.1:3000' + origins 'localhost:5173', '127.0.0.1:5173' - resource "*", - headers: :any, - methods: [:get, :post, :put, :patch, :delete, :options, :head] + resource '*', headers: :any, methods: %i[get post put patch delete options head] end end -- cgit v1.2.3