MCPcopy Create free account
hub / github.com/GoMudEngine/GoMud / Validate

Method Validate

internal/mutators/mutators.go:304–319  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

302}
303
304func (m *MutatorSpec) Validate() error {
305
306 if m.NameModifier != nil && !m.NameModifier.Behavior.IsValid() {
307 m.NameModifier.Behavior = TextDefault
308 }
309
310 if m.DescriptionModifier != nil && !m.DescriptionModifier.Behavior.IsValid() {
311 m.DescriptionModifier.Behavior = TextDefault
312 }
313
314 if m.AlertModifier != nil && !m.AlertModifier.Behavior.IsValid() {
315 m.AlertModifier.Behavior = TextDefault
316 }
317
318 return nil
319}
320
321// file self loads due to init()
322func LoadDataFiles() {

Callers 1

loadMutatorFileFromFSFunction · 0.95

Calls 1

IsValidMethod · 0.45

Tested by

no test coverage detected