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

Only store a single post for each hook #94

Open
JDGrimes opened this issue Apr 8, 2014 · 4 comments
Open

Only store a single post for each hook #94

JDGrimes opened this issue Apr 8, 2014 · 4 comments

Comments

@JDGrimes
Copy link
Contributor

JDGrimes commented Apr 8, 2014

At present we store an entry for a hook each time it appears in the source. But hooks are only documented once, with duplicate entries marked with a comment. We should ideally only store a single entry for each hook. The entry would then have metadata/something storing the specific data for each place the hook is used (file/function/method and line numbers).

The main issue is that right now post associations are done in a parent/child manner. Since a post can only have one parent, this will have to change. Posts 2 posts has been mentioned before.

@JDGrimes
Copy link
Contributor Author

JDGrimes commented Apr 8, 2014

Related: #42, #43

@JDGrimes
Copy link
Contributor Author

I'm new to posts 2 posts, but it looks like it would be a good solution to this. Post associations could also be used for #79. Any thoughts on adding that as a dependency, or alternative approaches that might be better?

@DrewAPicture
Copy link
Member

The problem with Posts to Posts is that's it's kind of a heavy-handed solution just for this. Might be better off just doing a poor-man's post relationship with a taxonomy mirroring a CPT.

@Rarst
Copy link
Contributor

Rarst commented Apr 15, 2014

If we need anything at all that doesn't work with basic WP inheritance (parent/child) we are looking into Posts2Posts (I would say "relationships libraries" but there aren't... many of them).

I am not making this into decision and my brain is stretched too thin right now, but I consider relationships definitely on the table as option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants