Skip to content

Using the container outside of Masonite flow #237

@eaguad1337

Description

@eaguad1337

In docs it appears the following code:

from wsgi import container
from masonite import Queue

class SomeCommand:

    def handle(self):
        queue = container.make(Queue)
        queue.push(..)

But wsgi module doesn't has any "container" class. I think it should be replaced with the following code.

from masonite.container import Container
from masonite import Queue

class SomeCommand:

    def handle(self):
        queue = Container().make(Queue)
        queue.push(..)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions