Compare commits

..

No commits in common. "60a2dcd73ffd36b12f7cde7150d875e466e75843" and "f3e0c6b374231f7f0d8dba1e23f42eac86f27250" have entirely different histories.

3 changed files with 9 additions and 4 deletions

View File

@ -14,7 +14,7 @@ defmodule Frenzy.Pipeline.Extractor.TheVerge do
content =
html_tree
|> Floki.find("main article > div:not(.duet--article--lede)")
|> Floki.find("article#content > div:not(.duet--article--lede)")
|> Floki.filter_out(
".hidden, .duet--layout--rail, .duet--article--article-pullquote, .duet--article--comments-join-the-conversation, .duet--recirculation--related-list, .duet--article--comments-button, .duet--article--share-buttons"
)
@ -57,7 +57,7 @@ defmodule Frenzy.Pipeline.Extractor.TheVerge do
end
end
defp rewrite({_tag, _attrs, children} = el) do
defp rewrite({tag, attrs, children} = el) do
cond do
is_empty_gif(el) ->
nil

View File

@ -15,7 +15,7 @@ defmodule FrenzyWeb.LoginController do
})
end
def login_post(conn, %{"username" => username, "password" => password}) do
def login_post(conn, %{"username" => username, "password" => password} = params) do
user = Repo.get_by(User, username: username)
case Bcrypt.check_pass(user, password) do
@ -54,7 +54,7 @@ defmodule FrenzyWeb.LoginController do
case conn.assigns.user do
%User{} = user ->
changeset = User.set_oidc_subject_changeset(user, %{oidc_subject: subject})
{:ok, _user} = Repo.update(changeset)
{:ok, user} = Repo.update(changeset)
conn
|> put_flash(:info, "Successfully linked OIDC.")

View File

@ -27,6 +27,11 @@ defmodule FrenzyWeb.ConfigureStage.ScrapeStageLive do
}
end)
@schema %{
"convert_to_data_uris" => :boolean,
"extractor" => :string
}
@impl true
def mount(socket) do
{:ok, assign(socket, extractors: @extractors)}