Update api URL

This change updates the production API URL to https://api.granblue.team/v1 instead of https://api.granblue.team/api/v1.
This commit is contained in:
Justin Edmund 2025-02-25 08:04:02 -05:00
parent 6db5faeb98
commit 3a8191ce03

View file

@ -4,8 +4,9 @@ Rails.application.routes.draw do
skip_controllers :applications, :authorized_applications
end
namespace :api, defaults: { format: :json } do
namespace :v1 do
path_prefix = Rails.env.production? ? '/v1' : '/api/v1'
scope path: path_prefix, module: 'api/v1', defaults: { format: :json } do
resources :parties, only: %i[index create update destroy]
resources :users, only: %i[create update show]
resources :grid_weapons, only: %i[update destroy]
@ -74,7 +75,6 @@ Rails.application.routes.draw do
delete 'favorites', to: 'favorites#destroy'
end
end
if Rails.env.development?
get '/party-previews/*filename', to: proc { |env|