1
0
Fork 0
forked from forgejo/forgejo

Remove dependency on queue from setting

This commit is contained in:
Andrew Thornton 2019-12-31 18:18:03 +00:00
parent 8798a61ba4
commit 030b6d91c8
No known key found for this signature in database
GPG key ID: 3CDE74631F13A748
7 changed files with 91 additions and 66 deletions

View file

@ -123,8 +123,8 @@ func RegisteredTypesAsString() []string {
return types
}
// CreateQueue takes a queue Type and HandlerFunc some options and possibly an exemplar and returns a Queue or an error
func CreateQueue(queueType Type, handlerFunc HandlerFunc, opts, exemplar interface{}) (Queue, error) {
// NewQueue takes a queue Type and HandlerFunc some options and possibly an exemplar and returns a Queue or an error
func NewQueue(queueType Type, handlerFunc HandlerFunc, opts, exemplar interface{}) (Queue, error) {
newFn, ok := queuesMap[queueType]
if !ok {
return nil, fmt.Errorf("Unsupported queue type: %v", queueType)