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

Allow user to define HoneypotDataProperty for functional Volt #124

Closed
wants to merge 3 commits into from
Closed

Allow user to define HoneypotDataProperty for functional Volt #124

wants to merge 3 commits into from

Conversation

jcsoriano
Copy link
Contributor

Related to #122

Problem

We're unable to use the package in Volt using functional syntax

Cause

The package depends on Reflection to guess the HoneypotData property, by checking which property has the HoneypotData type. Unfortunately, this is incompatible with Volt using functional syntax.

Solution

Add a method in the UsesSpamProtection trait getHoneypotDataProperty that allows user to specify which property is the HoneypotData property. If not specified, it falls back to Reflection to guess the property

@freekmurze
Copy link
Member

The tests fail for this one, could you take a look?

@jcsoriano
Copy link
Contributor Author

Hi @freekmurze updated the PR now :)

@jcsoriano jcsoriano marked this pull request as draft November 29, 2023 14:41
@jcsoriano
Copy link
Contributor Author

Converting to draft for now, I thought of a potential workaround. Will try that out first and message back here if it works

@jcsoriano
Copy link
Contributor Author

Hi @freekmurze I found a workaround without having to change any code in this package, I'll close this PR and just create another PR to update the docs to show people how to use this package with Volt in functional syntax 👍

@jcsoriano jcsoriano closed this Nov 29, 2023
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