From 1c96741de246faba41fbd345c0e20a48dc2bb096 Mon Sep 17 00:00:00 2001 From: crbelaus Date: Tue, 6 Aug 2024 16:32:28 +0200 Subject: [PATCH] Allow error_tracker_dashboard without parens This is consistent with how other packages such as Phoenix LiveDashboard or Oban work when mounting resources on the router. --- .formatter.exs | 6 +++++- dev.exs | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.formatter.exs b/.formatter.exs index 73d29a7..8881922 100644 --- a/.formatter.exs +++ b/.formatter.exs @@ -1,6 +1,10 @@ # Used by "mix format" +locals_without_parens = [error_tracker_dashboard: 1, error_tracker_dashboard: 2] + [ import_deps: [:ecto, :ecto_sql, :plug, :phoenix], inputs: ["{mix,.formatter,dev,dev.*}.exs", "{config,lib,test}/**/*.{heex,ex,exs}"], - plugins: [Phoenix.LiveView.HTMLFormatter] + plugins: [Phoenix.LiveView.HTMLFormatter], + locals_without_parens: locals_without_parens, + export: [locals_without_parens: locals_without_parens] ] diff --git a/dev.exs b/dev.exs index 08c33b1..b639d32 100644 --- a/dev.exs +++ b/dev.exs @@ -109,7 +109,7 @@ defmodule ErrorTrackerDevWeb.Router do get "/exit", ErrorTrackerDevWeb.PageController, :exit scope "/dev" do - error_tracker_dashboard("/errors") + error_tracker_dashboard "/errors" end end end