Initialize hubbackend inside memoryBackend
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Peter Stuifzand 2019-03-24 16:54:03 +01:00
parent e4fddac6fc
commit ecb893bccd
Signed by: peter
GPG Key ID: 374322D56E5209E8

View File

@ -119,9 +119,10 @@ func NewApp(options AppOptions) (*App, error) {
app.backend = loadMemoryBackend(options.pool)
app.backend.AuthEnabled = options.AuthEnabled
app.backend.baseURL = options.BaseURL
app.backend.pool = options.pool
app.backend.hubIncomingBackend.pool = options.pool
app.backend.hubIncomingBackend.baseURL = options.BaseURL
app.hubBackend = &hubIncomingBackend{app.backend, options.BaseURL, options.pool}
app.hubBackend = &hubIncomingBackend{backend: app.backend, baseURL: options.BaseURL, pool: options.pool}
http.Handle("/micropub", &micropubHandler{
Backend: app.backend,