Validate validates the app configuration
()
| 51 | |
| 52 | // Validate validates the app configuration |
| 53 | func (a *App) Validate() error { |
| 54 | if a.BaseURL == "" { |
| 55 | return ErrEmptyBaseURL |
| 56 | } |
| 57 | if a.Clock == nil { |
| 58 | return ErrEmptyClock |
| 59 | } |
| 60 | if a.EmailBackend == nil { |
| 61 | return ErrEmptyEmailBackend |
| 62 | } |
| 63 | if a.DB == nil { |
| 64 | return ErrEmptyDB |
| 65 | } |
| 66 | if a.HTTP500Page == nil { |
| 67 | return ErrEmptyHTTP500Page |
| 68 | } |
| 69 | |
| 70 | return nil |
| 71 | } |