Skip to content

Commit 37ed1c4

Browse files
committed
refactor: 自作プレビュー機能を削除し、Rambulanceのルートに統一
自作していたエラーページのプレビュー機能 ( と関連ルーティング) を削除しました。 先ほどのビューファイル名の修正により、Rambulanceが の末尾で定義しているプレビュー用ルート (, など) で正しく表示できるようになったため、このリファクタリングを実施します。 よりシンプルでメンテナンスしやすい構成になります。
1 parent 561e698 commit 37ed1c4

File tree

2 files changed

+0
-26
lines changed

2 files changed

+0
-26
lines changed

app/controllers/previews/errors_controller.rb

Lines changed: 0 additions & 20 deletions
This file was deleted.

config/routes.rb

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -111,12 +111,6 @@
111111
# Check development sent emails
112112
mount LetterOpenerWeb::Engine, at: "/letter_opener" if Rails.env.development?
113113

114-
if Rails.env.development?
115-
namespace :previews do
116-
get "errors/:status_code", to: "errors#show"
117-
end
118-
end
119-
120114
# Rambulance がキャッチする /404, /422, /500
121115
match "/404", to: Rambulance::Engine, via: :all, defaults: { status_code: 404 }
122116
match "/422", to: Rambulance::Engine, via: :all, defaults: { status_code: 422 }

0 commit comments

Comments
 (0)