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

let replacement access all data like {url} #157

Closed
wants to merge 2 commits into from
Closed

let replacement access all data like {url} #157

wants to merge 2 commits into from

Conversation

laoyuan
Copy link

@laoyuan laoyuan commented Jun 11, 2016

Now you can:
php artisan notifynder:create:category "post.comment" "{from.name} leave a comment to <a href=\"{url}\">your post</a>"

@Gummibeer
Copy link
Collaborator

In this case you can simply remove the array_filter() the mixedGet() checks for this and if it returns an empty value it doesn't replace anything.
This will save a bit of logic.

After this change can you please add/extend unittests to cover the new logic/possibilities.

@laoyuan
Copy link
Author

laoyuan commented Jun 11, 2016

@Gummibeer I think array_filter() is necessary to check, so I just add a test.

@Gummibeer
Copy link
Collaborator

To check what? The mixedGet can't return a not existing value.

@laoyuan
Copy link
Author

laoyuan commented Jun 13, 2016

@Gummibeer I don't want to remove all {xxx}, so check if xxx is a property name first.

@Gummibeer
Copy link
Collaborator

Ok, cause there could be a case when this is part of the real message - now I got it, thanks!
I will take a look at it and extend the unittests and will merge it.

@Gummibeer Gummibeer added this to the v4.0 milestone Jul 1, 2016
@Gummibeer Gummibeer self-assigned this Jul 1, 2016
@Gummibeer
Copy link
Collaborator

is already implemented in v4 - cause of inactivity I will close this PR.

@Gummibeer Gummibeer closed this Jul 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants