Sha256: 5935d40f92cc9789831aa10663fa255cc5b12e2c830b29f3d95a9c344411fbb7
Contents?: true
Size: 628 Bytes
Versions: 4
Compression:
Stored size: 628 Bytes
Contents
# frozen_string_literal: true module RailsDevtools module Routes class RoutePathInputsController < ApplicationController def update route = Routes::Collection.find(params[:id]) input_params = { route: route } if params[:engine_prefix].present? && params[:engine_prefix] == "1" input_params.merge!(prefix: route.engine_info.helper_prefix) end if params[:url_suffix].present? && params[:url_suffix] == "1" input_params.merge!(suffix: "url") end render Routes::RouteDetails::RoutePathInput.new(**input_params) end end end end
Version data entries
4 entries across 4 versions & 1 rubygems