Skip to content

Force set cookie if exception occurs when getting cookie - #8

Open
UsefulJeroen wants to merge 1 commit into
nemi-chand:masterfrom
UsefulJeroen:HandleExceptions
Open

Force set cookie if exception occurs when getting cookie#8
UsefulJeroen wants to merge 1 commit into
nemi-chand:masterfrom
UsefulJeroen:HandleExceptions

Conversation

@UsefulJeroen

Copy link
Copy Markdown

Sometimes I get an exception when I want to get a Cookie.
But while using the GetOrSet method, this shouldn't happen.
If the get request fails, the method should set the cookie with the given value (aquirer).
Please provide feedback if this is not the expected behavior.

@nemi-chand

Copy link
Copy Markdown
Owner

@swing7wing Thanks for the PR
Could you please help me to understand what error generally occur in your case?

@UsefulJeroen

Copy link
Copy Markdown
Author

Specifically the unblocking of the previous cookie content. But this pull request won't specifically fix this problem. This will just force set the value if it can't retrieve the previous cookie value. I assume the expected behavior is to use the value that's being given as parameter in the GetOrSet function (Func acquirer) when it can't retrieve a value in the Get function.
This could also circumvent this problem for occuring in the future because this is a non specific try catch.

@UsefulJeroen

UsefulJeroen commented Aug 26, 2020

Copy link
Copy Markdown
Author

Any update about this pull request? Would be great to have this feature in our project. Because this is something we currently have to handle ourselves in the project.

@UsefulJeroen

Copy link
Copy Markdown
Author

Hi, any update about this pull request? Would be nice to have included in this project.

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

Successfully merging this pull request may close these issues.

2 participants