projects
/
akkoma
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
add inbound language test
[akkoma]
/
lib
/
pleroma
/
iso639.ex
1
defmodule Pleroma.ISO639 do
2
@file "priv/language-codes.json"
3
@data File.read!(@file)
4
|> Jason.decode!()
5
6
for %{"alpha2" => alpha2} <- @data do
7
def valid_alpha2?(unquote(alpha2)), do: true
8
end
9
10
def valid_alpha2?(_alpha2), do: false
11
end