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

Login Filter before error in version 4.1.2 #361

Closed
byruddy opened this issue May 26, 2021 · 7 comments
Closed

Login Filter before error in version 4.1.2 #361

byruddy opened this issue May 26, 2021 · 7 comments

Comments

@byruddy
Copy link

byruddy commented May 26, 2021

I recieve this error when attempting to use the Login Filter for any route:

ErrorException #64
Declaration of Myth\Auth\Filters\LoginFilter::before(CodeIgniter\HTTP\RequestInterface $request) must be compatible with CodeIgniter\Filters\FilterInterface::before(CodeIgniter\HTTP\RequestInterface $request, $arguments = NULL) 

It looks like the newest CI version expects before filters to take $arguments = NULL as a parameter. I can't downgrade the version or I get errors with the withCookies() function.

And I have follow tutorial for downgrade #253 , still same error

@MGatner
Copy link
Collaborator

MGatner commented May 26, 2021

You need to update your version of Myth:Auth or manually edit the files.

@byruddy
Copy link
Author

byruddy commented May 26, 2021

You need to update your version of Myth:Auth or manually edit the files.

what version ?

@MGatner
Copy link
Collaborator

MGatner commented May 26, 2021

The latest of develop. The last release was May 2020 and this was fixed July 2020 (#250), so no release will have the updated filters. You can use the instructions on the linked issue for switching to dev-develop as your dependency.

@byruddy
Copy link
Author

byruddy commented May 26, 2021

The latest of develop. The last release was May 2020 and this was fixed July 2020 (#250), so no release will have the updated filters. You can use the instructions on the linked issue for switching to dev-develop as your dependency.

What do you mean by this:

"minimum-stability": "dev-develop",

@MGatner
Copy link
Collaborator

MGatner commented May 26, 2021

Here's what I recommend (this will obviously have to be merged with your other settings in composer.json):

	"require": {
		"myth/auth": "dev-develop"
	},
	"repositories": [
		{
			"type": "vcs",
			"url": "https://github.com/lonnieezell/myth-auth"
		}
	],
	"minimum-stability": "dev",
	"prefer-stable": true,

@byruddy
Copy link
Author

byruddy commented May 26, 2021

Here's what I recommend (this will obviously have to be merged with your other settings in composer.json):

	"require": {
		"myth/auth": "dev-develop"
	},
	"repositories": [
		{
			"type": "vcs",
			"url": "https://github.com/lonnieezell/myth-auth"
		}
	],
	"minimum-stability": "dev",
	"prefer-stable": true,

Still error, you can check this picture :
config
result

@MGatner
Copy link
Collaborator

MGatner commented May 26, 2021

At this point you need troubleshooting and support, which I will not offer here. I recommend you go to the forums if you cannot figure it out.

This is not a bug with the library other than the latest version being very stale. I will recommend to @lonnieezell that he publish a maintenance release so this is easier for downstream users.

@MGatner MGatner closed this as completed May 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants