-
-
Notifications
You must be signed in to change notification settings - Fork 42
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
Review permalink issue #253
Conversation
Merge pull request wp-document-revisions#250 from NeilWJames/master
This represents aligning to the wp-die-fix branch whilst remaining with travis and not github actions. The contents of test is simply the code in the wp-die-fix branch.
Also set as show_in_rest.
Match if year/month and/or file extension not entered. Will match with just the post name - just like a post,
Codecov Report
@@ Coverage Diff @@
## master #253 +/- ##
============================================
+ Coverage 44.84% 45.76% +0.92%
+ Complexity 628 625 -3
============================================
Files 7 7
Lines 2143 2137 -6
============================================
+ Hits 961 978 +17
+ Misses 1182 1159 -23
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow, this is great. I especially like how you broke up the plain vs pretty permalink tests. Definitely a lot more confident about permalink handling going forward given the challenge folks have been facing in the forum - thank you.
And thank you for all your housekeeping documentation! Much appreciated! 🙇🏻 |
I can go ahead and get this merged. Given that there's so many great features and fixes in |
The problem with the multisite test was actually due to the environment having plain permalink style. The normal style is /year/month/post_name/.
Plain results in a name like .../post_type=document?p=7
For a revision this was .../post_type=document?&p=7&revision=1.txt (for a text file loaded)
Code has been changed to be ../post_type=document?&p=7&revision=1 which will work.
The admin tests have been changed to incorporate running tests with Plain and Year/Month/Post_name styles.
Separately I have extended the rewrite matching rules to not require the year/month and or the file extension. My logic for doing this is that standard WP will find the document if you enter ....index.php?document=post_name so allowing .../documents/post_name is the same really.
I have made workflow_state appear on the admin list of documents using standard WP functionality and updated the Read mes.
I have updated the code coverage badge too.
Neil James