Skip to content

Commit

Permalink
FIXUP
Browse files Browse the repository at this point in the history
  • Loading branch information
whatyouhide committed Aug 20, 2024
1 parent c2576ef commit 685c961
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions installer/templates/phx_single/lib/app_name_web.ex
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ defmodule <%= @web_namespace %> do
formats: [:html, :json],
layouts: [html: <%= @web_namespace %>.Layouts]
<%= if @gettext do %>
use Gettext, backend: <%= @web_namespace %>.Gettext<% end %>

use Gettext, backend: <%= @web_namespace %>.Gettext
<% end %>
import Plug.Conn

unquote(verified_routes())
Expand Down Expand Up @@ -81,9 +81,9 @@ defmodule <%= @web_namespace %> do
end

defp html_helpers do
quote do
quote do<%= if @gettext do %>
# Translation
<%= if @gettext do %>use Gettext, backend: <%= @web_namespace %>.Gettext
use Gettext, backend: <%= @web_namespace %>.Gettext
<% end %>
# HTML escaping functionality
import Phoenix.HTML
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ defmodule <%= @web_namespace %> do
use Phoenix.Controller,
formats: [:html, :json],
layouts: [html: <%= @web_namespace %>.Layouts]
<%= if @gettext do %>use Gettext, backend: <%= @web_namespace %>.Gettext
<%= if @gettext do %>
use Gettext, backend: <%= @web_namespace %>.Gettext
<% end %>
import Plug.Conn

Expand Down Expand Up @@ -81,9 +81,9 @@ defmodule <%= @web_namespace %> do
end

defp html_helpers do
quote do
quote do<%= if @gettext do %>
# Translation
<%= if @gettext do %>use Gettext, backend: <%= @web_namespace %>.Gettext
use Gettext, backend: <%= @web_namespace %>.Gettext
<% end %>
# HTML escaping functionality
import Phoenix.HTML
Expand All @@ -96,7 +96,6 @@ defmodule <%= @web_namespace %> do
# Routes generation with the ~p sigil
unquote(verified_routes())
end
end<% end %>

def verified_routes do
quote do
Expand Down
2 changes: 1 addition & 1 deletion installer/templates/phx_umbrella/apps/app_name_web/mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ defmodule <%= @web_namespace %>.MixProject do
depth: 1},<% end %>
{:telemetry_metrics, "~> 1.0"},
{:telemetry_poller, "~> 1.0"},<%= if @gettext do %>
{:gettext, "~> 0.20"},<% end %><%= if @app_name != @web_app_name do %>
{:gettext, "~> 0.26"},<% end %><%= if @app_name != @web_app_name do %>
{:<%= @app_name %>, in_umbrella: true},<% end %>
{:jason, "~> 1.2"},
{<%= inspect @web_adapter_app %>, "<%= @web_adapter_vsn %>"}
Expand Down
2 changes: 1 addition & 1 deletion integration_test/mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ defmodule Phoenix.Integration.MixProject do
{:phoenix_live_dashboard, "~> 0.8.3"},
{:telemetry_metrics, "~> 1.0"},
{:telemetry_poller, "~> 1.0"},
{:gettext, "~> 0.20"},
{:gettext, "~> 0.26"},
{:jason, "~> 1.2"},
{:swoosh, "~> 1.16"},
{:bandit, "~> 1.0"},
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ defmodule Phoenix.MixProject do
{:ex_doc, "~> 0.24", only: :docs},
{:ecto, "~> 3.0", only: :docs},
{:ecto_sql, "~> 3.10", only: :docs},
{:gettext, "~> 0.20", only: :docs},
{:gettext, "~> 0.26", only: :docs},
{:telemetry_poller, "~> 1.0", only: :docs},
{:telemetry_metrics, "~> 1.0", only: :docs},
{:makeup_eex, ">= 0.1.1", only: :docs},
Expand Down
1 change: 1 addition & 0 deletions mix.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"ecto_sql": {:hex, :ecto_sql, "3.10.1", "6ea6b3036a0b0ca94c2a02613fd9f742614b5cfe494c41af2e6571bb034dd94c", [:mix], [{:db_connection, "~> 2.5 or ~> 2.4.1", [hex: :db_connection, repo: "hexpm", optional: false]}, {:ecto, "~> 3.10.0", [hex: :ecto, repo: "hexpm", optional: false]}, {:myxql, "~> 0.6.0", [hex: :myxql, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.16.0 or ~> 0.17.0 or ~> 1.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:tds, "~> 2.1.1 or ~> 2.2", [hex: :tds, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "f6a25bdbbd695f12c8171eaff0851fa4c8e72eec1e98c7364402dda9ce11c56b"},
"esbuild": {:hex, :esbuild, "0.8.1", "0cbf919f0eccb136d2eeef0df49c4acf55336de864e63594adcea3814f3edf41", [:mix], [{:castore, ">= 0.0.0", [hex: :castore, repo: "hexpm", optional: false]}, {:jason, "~> 1.4", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "25fc876a67c13cb0a776e7b5d7974851556baeda2085296c14ab48555ea7560f"},
"ex_doc": {:hex, :ex_doc, "0.34.0", "ab95e0775db3df71d30cf8d78728dd9261c355c81382bcd4cefdc74610bef13e", [:mix], [{:earmark_parser, "~> 1.4.39", [hex: :earmark_parser, repo: "hexpm", optional: false]}, {:makeup_c, ">= 0.1.0", [hex: :makeup_c, repo: "hexpm", optional: true]}, {:makeup_elixir, "~> 0.14 or ~> 1.0", [hex: :makeup_elixir, repo: "hexpm", optional: false]}, {:makeup_erlang, "~> 0.1 or ~> 1.0", [hex: :makeup_erlang, repo: "hexpm", optional: false]}, {:makeup_html, ">= 0.1.0", [hex: :makeup_html, repo: "hexpm", optional: true]}], "hexpm", "60734fb4c1353f270c3286df4a0d51e65a2c1d9fba66af3940847cc65a8066d7"},
"expo": {:hex, :expo, "1.0.0", "647639267e088717232f4d4451526e7a9de31a3402af7fcbda09b27e9a10395a", [:mix], [], "hexpm", "18d2093d344d97678e8a331ca0391e85d29816f9664a25653fd7e6166827827c"},
"gettext": {:hex, :gettext, "0.20.0", "75ad71de05f2ef56991dbae224d35c68b098dd0e26918def5bb45591d5c8d429", [:mix], [], "hexpm", "1c03b177435e93a47441d7f681a7040bd2a816ece9e2666d1c9001035121eb3d"},
"hpax": {:hex, :hpax, "0.1.1", "2396c313683ada39e98c20a75a82911592b47e5c24391363343bde74f82396ca", [:mix], [], "hexpm", "0ae7d5a0b04a8a60caf7a39fcf3ec476f35cc2cc16c05abea730d3ce6ac6c826"},
"jason": {:hex, :jason, "1.4.0", "e855647bc964a44e2f67df589ccf49105ae039d4179db7f6271dfd3843dc27e6", [:mix], [{:decimal, "~> 1.0 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "79a3791085b2a0f743ca04cec0f7be26443738779d09302e01318f97bdb82121"},
Expand Down

0 comments on commit 685c961

Please sign in to comment.