Skip to content

Conversation

@markm68k
Copy link

• Ensure that pathBySettingSVGAttributes: always returns a non-null value. • If [self copy] returns nil, return self or create a new instance as a fallback. • Add a comment explaining the fallback.

Thank you for submitting a PR for PocketSVG 😀

  • If you're fixing an issue, please briefly describe the current behaviour and the new behaviour. If you're addressing an open issue, please link to it.

  • If you're introducing a new feature, please briefly describe the new behavior and provide code + sample SVGs for us to see it in action.

Please also add that as an entry in our CHANGELOG.md file to explain your changes and credit yourself. Add the entry in the appropriate section (New Features / Fixes / Internal Change / Breaking Change) under Unreleased. Add links to your GitHub profile and to the related PR and issue after your description. Be part of history.

• Ensure that pathBySettingSVGAttributes: always returns a non-null value.
• If [self copy] returns nil, return self or create a new instance as a fallback.
• Add a comment explaining the fallback.
@markm68k
Copy link
Author

markm68k commented Oct 26, 2025

Oops, I made a mistake with my comments.

• Ensure that fillColor and strokeColor do not return nil. If _svgLayer.fillColor (or .strokeColor) is nil, return a default color such as [PSVGColor blackColor], or whatever is appropriate for your usage.
• This change ensures the methods always return a non-nil value and prevents analyzer complaints.

@markm68k
Copy link
Author

Addresses open issue #230

@markm68k markm68k closed this by deleting the head repository Nov 10, 2025
@arielelkin
Copy link
Collaborator

thanks for your patience! this has now been fixed via 1f5b96a

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants