Skip to content

Remove unnecessary optional so example compiles - #501

Open
mattmassicotte wants to merge 1 commit into
apple:mainfrom
mattmassicotte:fix/optional-in-loghandler-example
Open

Remove unnecessary optional so example compiles#501
mattmassicotte wants to merge 1 commit into
apple:mainfrom
mattmassicotte:fix/optional-in-loghandler-example

Conversation

@mattmassicotte

Copy link
Copy Markdown

There's an unnecessary optional return here that prevents the example from compiling.

Motivation:

It took me a moment to figure out how to fix this, but in the end it was very straightforward. The prepareMetadata doesn't ever need to return nil.

Modifications:

A small type change fixes the compilation errors in log(event:)

Result:

The example in the documentation can now be used unmodified.

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.

1 participant