Skip to content

Correct error with the plugin's get_excerpt() function.#186

Open
laurelfulford wants to merge 1 commit intoINN:masterfrom
laurelfulford:fixes/185-search-saved-links-error
Open

Correct error with the plugin's get_excerpt() function.#186
laurelfulford wants to merge 1 commit intoINN:masterfrom
laurelfulford:fixes/185-search-saved-links-error

Conversation

@laurelfulford
Copy link

Changes

This PR passes the expected $post to the_except() function in SavedLinks, to prevent errors.

Why

This PR is to fix an issue I noticed when using the Link Roundups plugin with a theme that was not Largo. If you run a search that returns a Saved Link CPT, it throws an error.

For #185

Testing/Questions

Features that this PR affects:

  • Saved Links CPT

Questions that need to be answered before merging:

  • Is this PR targeting the correct branch in this repository?

(I believe so, but please let me know if it's not!)

Steps to test this PR:

  1. On a test site, apply a theme that is not Largo -- a good bet is one of the default themes, like Twenty Twenty.
  2. If you don't have any, add at least one "Saved Link"
  3. Run a search on the front-end of the site; note that you get an error:

image

  1. Apply the PR.
  2. Confirm that the error is now gone, and the search results are displaying as expected:

image

Additional information

INN Member/Labs Client requesting: (if applicable)

  • Contributor has read INN's GitHub code of conduct
  • Contributor would like to be mentioned in the release notes as: Laurel Fulford
  • Contributor agrees to the license terms of this repository.

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.

2 participants