Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/bump-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ jobs:

- name: Format the version changelog
run: |
PARSELY_RELEASE_LOG=$(printf '%s' "$PARSELY_RELEASE_LOG" | sed 's/###/##/g')
PARSELY_RELEASE_LOG=$(printf '%s' "$PARSELY_RELEASE_LOG" | sed 's/###/##/g' | sed 's/^[[:space:]]*//')
echo $PARSELY_RELEASE_LOG
# Write the multiline variable to $GITHUB_ENV using the correct syntax
echo "PARSELY_RELEASE_LOG<<EOF" >> $GITHUB_ENV
Expand All @@ -120,4 +120,5 @@ jobs:
$PARSELY_RELEASE_LOG" \
--base ${{ github.ref_name }} \
--head update/wp-parsely-version-to-${{ env.NEW_VERSION }} \
--assignee ${{ github.actor }}
--assignee ${{ github.actor }} \
--milestone ${{ env.NEW_VERSION }}
3 changes: 2 additions & 1 deletion .github/workflows/release-plugin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,10 @@ jobs:
TAG_NAME="${{ env.VERSION }}"
if ${{ env.DRY_RUN }}; then
TAG_NAME="dry-run-${{ env.VERSION }}"
# If the tag already exists, delete the tag
# If the tag already exists, delete it both locally and remotely
if git tag --list | grep -q "${TAG_NAME}"; then
git tag -d "${TAG_NAME}"
git push --delete origin ":refs/tags/${TAG_NAME}" || true
fi
fi

Expand Down
4 changes: 2 additions & 2 deletions src/content-helper/editor-sidebar/class-editor-sidebar.php
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ private function get_parsely_post_url( $post_id = null, bool $add_utm_params = t
/**
* The post object.
*
* @var WP_Post $post
* @var WP_Post|null $post
*/
$post = get_post( $post_id );

if ( ! Dashboard_Link::can_show_link( $post, $this->parsely ) ) {
if ( null === $post || ! Dashboard_Link::can_show_link( $post, $this->parsely ) ) {
return null;
}

Expand Down
Loading