mirror of
https://github.com/dillonkearns/elm-pages-v3-beta.git
synced 2025-01-07 15:01:37 +03:00
Remove some redundant declarations.
This commit is contained in:
parent
92abb27596
commit
49e8360030
@ -113,6 +113,17 @@ nextStep :
|
||||
-> ( StaticResponses, NextStep route )
|
||||
nextStep ({ allRawResponses, errors } as model) maybeRoutes =
|
||||
let
|
||||
staticRequestsStatus : StaticHttpRequest.Status ()
|
||||
staticRequestsStatus =
|
||||
allRawResponses
|
||||
|> StaticHttpRequest.cacheRequestResolution request
|
||||
|
||||
request : DataSource ()
|
||||
request =
|
||||
case staticResponses of
|
||||
NotFetched request_ _ ->
|
||||
request_
|
||||
|
||||
staticResponses : StaticHttpResult
|
||||
staticResponses =
|
||||
case model.staticResponses of
|
||||
@ -128,13 +139,8 @@ nextStep ({ allRawResponses, errors } as model) maybeRoutes =
|
||||
pendingRequests : Bool
|
||||
pendingRequests =
|
||||
case staticResponses of
|
||||
NotFetched request rawResponses ->
|
||||
NotFetched _ rawResponses ->
|
||||
let
|
||||
staticRequestsStatus : StaticHttpRequest.Status ()
|
||||
staticRequestsStatus =
|
||||
allRawResponses
|
||||
|> StaticHttpRequest.cacheRequestResolution request
|
||||
|
||||
hasPermanentError : Bool
|
||||
hasPermanentError =
|
||||
case staticRequestsStatus of
|
||||
@ -177,15 +183,8 @@ nextStep ({ allRawResponses, errors } as model) maybeRoutes =
|
||||
True
|
||||
in
|
||||
if pendingRequests then
|
||||
let
|
||||
requestContinuations : DataSource ()
|
||||
requestContinuations =
|
||||
case staticResponses of
|
||||
NotFetched request _ ->
|
||||
request
|
||||
in
|
||||
case
|
||||
performStaticHttpRequests allRawResponses requestContinuations
|
||||
performStaticHttpRequests allRawResponses request
|
||||
of
|
||||
urlsToPerform ->
|
||||
let
|
||||
@ -229,19 +228,7 @@ nextStep ({ allRawResponses, errors } as model) maybeRoutes =
|
||||
let
|
||||
failedRequests : List BuildError
|
||||
failedRequests =
|
||||
case staticResponses of
|
||||
NotFetched request _ ->
|
||||
let
|
||||
staticRequestsStatus : StaticHttpRequest.Status ()
|
||||
staticRequestsStatus =
|
||||
StaticHttpRequest.cacheRequestResolution
|
||||
request
|
||||
usableRawResponses
|
||||
|
||||
usableRawResponses : RequestsAndPending
|
||||
usableRawResponses =
|
||||
allRawResponses
|
||||
|
||||
maybePermanentError : Maybe StaticHttpRequest.Error
|
||||
maybePermanentError =
|
||||
case staticRequestsStatus of
|
||||
@ -308,19 +295,7 @@ nextStep ({ allRawResponses, errors } as model) maybeRoutes =
|
||||
let
|
||||
failedRequests : List BuildError
|
||||
failedRequests =
|
||||
case staticResponses of
|
||||
NotFetched request _ ->
|
||||
let
|
||||
staticRequestsStatus : StaticHttpRequest.Status ()
|
||||
staticRequestsStatus =
|
||||
StaticHttpRequest.cacheRequestResolution
|
||||
request
|
||||
usableRawResponses
|
||||
|
||||
usableRawResponses : RequestsAndPending
|
||||
usableRawResponses =
|
||||
allRawResponses
|
||||
|
||||
maybePermanentError : Maybe StaticHttpRequest.Error
|
||||
maybePermanentError =
|
||||
case staticRequestsStatus of
|
||||
|
Loading…
Reference in New Issue
Block a user