Remove unused flags.
This commit is contained in:
parent
47e8969290
commit
c88f2f3b3c
14
src/Main.elm
14
src/Main.elm
|
@ -25,17 +25,13 @@ import Task
|
||||||
syncTimeout = 10000
|
syncTimeout = 10000
|
||||||
typingTimeout = 2000
|
typingTimeout = 2000
|
||||||
|
|
||||||
type alias Flags =
|
init : () -> Url -> Nav.Key -> (Model, Cmd Msg)
|
||||||
{ token : Maybe String
|
init _ url key =
|
||||||
}
|
|
||||||
|
|
||||||
init : Flags -> Url -> Nav.Key -> (Model, Cmd Msg)
|
|
||||||
init flags url key =
|
|
||||||
let
|
let
|
||||||
model =
|
model =
|
||||||
{ key = key
|
{ key = key
|
||||||
, route = Maybe.withDefault Unknown <| parse Scylla.Route.route url
|
, route = Maybe.withDefault Unknown <| parse Scylla.Route.route url
|
||||||
, token = flags.token
|
, token = Nothing
|
||||||
, loginUsername = ""
|
, loginUsername = ""
|
||||||
, loginPassword = ""
|
, loginPassword = ""
|
||||||
, apiUrl = "https://matrix.org"
|
, apiUrl = "https://matrix.org"
|
||||||
|
@ -50,9 +46,7 @@ init flags url key =
|
||||||
, transactionId = 0
|
, transactionId = 0
|
||||||
, userData = Dict.empty
|
, userData = Dict.empty
|
||||||
}
|
}
|
||||||
cmd = case flags.token of
|
cmd = getStoreValuePort "scylla.loginInfo"
|
||||||
Just _ -> Cmd.none
|
|
||||||
Nothing -> getStoreValuePort "scylla.loginInfo"
|
|
||||||
in
|
in
|
||||||
(model, cmd)
|
(model, cmd)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user