Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to use the package | Non-static method printers() cannot be called statically #25

Closed
MuhammadAbbasAkhtar opened this issue Jul 30, 2021 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@MuhammadAbbasAkhtar
Copy link

I have installed this package on a fresh installation, completed all the steps from the Docs. Using CUPS and getting this error
Non-static method Rawilk\Printing\Printing::printers() cannot be called statically

I have setup the cups server info in the env and the server is accessible from browser.

I tried using it like this $printer = (new Printing)->printers(); and got this error Too few arguments to function Rawilk\Printing\Printing::__construct()

@MuhammadAbbasAkhtar MuhammadAbbasAkhtar added the bug Something isn't working label Jul 30, 2021
@cntabana
Copy link

I have installed this package on a fresh installation, completed all the steps from the Docs. Using CUPS and getting this error
Non-static method Rawilk\Printing\Printing::printers() cannot be called statically

Make sure you import facade instead of the printing class.
using this namespace use Rawilk\Printing\Facades\Printing instead of this one use Rawilk\Printing

@rawilk
Copy link
Owner

rawilk commented Feb 10, 2022

@cntabana is correct. Make sure you're using the facade.

@rawilk rawilk closed this as completed Feb 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants