• Operand
  • # (b)ring mi - belles.

gram:op

> ./lib/op_web/course.ex

Lenses
(coming soon!)


# prior:
#   - source: //ghub:UrbanOS-Public/smartcitiesdata (AndiWeb.Redirect)
#     license: Apache License v2,
#   - source: https://www.viget.com/articles/how-to-redirect-from-the-phoenix-router/
defmodule OpWeb.Course do
  @moduledoc """
  Plug in addresses,
  and pull up your pages,
  in Elixir & Phoenix,
  and someday Gleam.
  """

  def init(opts) do
    if Keyword.has_key?(opts, :to), do: opts,
      else: raise("please include ':to' `Course`.")
  end

  def call(conn, opts) do
    conn |> Phoenix.Controller.redirect(opts)
  end
end