1
0
Fork 0

fixed some pelling mistakes

Dieser Commit ist enthalten in:
Sebastian Tobie 2021-10-25 22:28:39 +02:00
Ursprung 2fff12e6f4
Commit 608bc051d2
3 geänderte Dateien mit 8 neuen und 8 gelöschten Zeilen

Datei anzeigen

@ -18,11 +18,11 @@ const (
var rauthmap = map[Rauth]string{
ReqAuthAbsent: "Authentication Absent",
ReqAuthRequired: "Authntication Required",
ReqAuthRequired: "Authentication Required",
ReqAuthUnspec: "Authentication irrelevant",
}
// String is to Statisfy th Stringer interface
// String is to Statisfy the Stringer interface
func (r *Rauth) String() string {
return rauthmap[*r]
}
@ -78,10 +78,10 @@ func (m *MenuItem) Children() []Menu {
// Enabled returns always true
func (m *MenuItem) Enabled(a auth.Account) bool {
switch m.RequireAuth {
case ReqAuthAbsent:
return true && a.Anonymous()
case ReqAuthUnspec:
return true
case ReqAuthAbsent:
return true && a.Anonymous()
case ReqAuthRequired:
return true && !a.Anonymous()
}

Datei anzeigen

@ -51,7 +51,7 @@ func gencases(t *testing.T) []Case {
seen: true && !authenticated,
}
cases = append(cases, c)
t.Logf("Absent Case, athenticated: %t, seen: %t", authenticated, c.seen)
t.Logf("Absent Case, authenticated: %t, seen: %t", authenticated, c.seen)
case menus.ReqAuthRequired:
c := Case{
menu: menus.MenuItem{
@ -61,7 +61,7 @@ func gencases(t *testing.T) []Case {
seen: true && authenticated,
}
cases = append(cases, c)
t.Logf("Required Case, athenticated: %t, seen: %t", authenticated, c.seen)
t.Logf("Required Case, authenticated: %t, seen: %t", authenticated, c.seen)
case menus.ReqAuthUnspec:
c := Case{
menu: menus.MenuItem{
@ -71,7 +71,7 @@ func gencases(t *testing.T) []Case {
seen: true,
}
cases = append(cases, c)
t.Logf("Uspec Case, athenticated: %t, seen: %t", authenticated, c.seen)
t.Logf("Unspec Case, authenticated: %t, seen: %t", authenticated, c.seen)
}
}
}

Datei anzeigen

@ -111,7 +111,7 @@ func (m *Middleware) Teardown() {
func logmigrations(version int32, name string, dir string, sql string) {
sql = ""
log.Info().Int32("version", version).Str("name", name).Str("dir", dir).Msgf("Running Migration %s with version %i in %sward direction", name, version, dir)
log.Info().Int32("version", version).Str("name", name).Str("dir", dir).Msgf("Running Migration %s with version %d in %sward direction", name, version, dir)
}
// SetupMigrator sets up the migrator to migrate the database.