Fix handling of --contentDir etc. flag

We need to revisit the commands package re globals and tests, but this should fix the init order of flags and languages.

Fixes #4589
This commit is contained in:
Bjørn Erik Pedersen 2018-04-07 11:27:22 +02:00
parent 094ec17142
commit 080302eb87
No known key found for this signature in database
GPG key ID: 330E6E2BD4859D8F
4 changed files with 89 additions and 56 deletions

View file

@ -137,6 +137,11 @@ func server(cmd *cobra.Command, args []string) error {
c.Set("watch", true)
}
// TODO(bep) yes, we should fix.
if !c.languagesConfigured {
return nil
}
var err error
// We can only do this once.