Simplify method to get the toggle selection path

This commit is contained in:
Javi Martín
2021-08-20 02:26:20 +02:00
parent 3febe3f0cc
commit 43b6ab00e3
2 changed files with 2 additions and 7 deletions

View File

@@ -24,7 +24,7 @@ module ActionDispatch::Routing::UrlFor
end
def namespaced_polymorphic_path(namespace, resource, options = {})
if %w[Budget::Group Budget::Heading Legislation::DraftVersion Legislation::Question
if %w[Budget::Group Budget::Heading Legislation::DraftVersion Legislation::Proposal Legislation::Question
Poll::Booth Poll::BoothAssignment Poll::Officer Poll::Question Poll::Question::Option
Poll::Question::Option::Video Poll::Shift SDG::LocalTarget].include?(resource.class.name)
resolve = resolve_for(resource)