Skip to content
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

Fix empty keyed encoding #123

Merged
merged 2 commits into from
Feb 19, 2019
Merged

Fix empty keyed encoding #123

merged 2 commits into from
Feb 19, 2019

Conversation

baarde
Copy link
Sponsor Contributor

@baarde baarde commented Feb 15, 2019

This fixes #122.

@tanner0101 tanner0101 added the bug Something isn't working label Feb 16, 2019
@tanner0101 tanner0101 added this to In Progress in Vapor 3 via automation Feb 16, 2019
Copy link
Member

@tanner0101 tanner0101 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great change, thank you. This is a much better approach.

@@ -332,6 +332,12 @@ class PostgreSQLConnectionTests: XCTestCase {
print(row)
}

func testRowCodableEmptyKeyed() throws {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add this to the allTests array at the bottom of the file?

Copy link
Sponsor Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops. I always forget allTests. Fixed.

…ner is requested

The encoder will fallback to JSONB using JSONEncoder even if the encoded type does not encode any key.
@tanner0101 tanner0101 merged commit d34cf72 into vapor:1 Feb 19, 2019
@tanner0101
Copy link
Member

Thanks :)

@penny-coin
Copy link

Hey @baarde, you just merged a pull request, have a coin!

You now have 8 coins.

@tanner0101 tanner0101 moved this from In Progress to Done in Vapor 3 Feb 19, 2019
@baarde baarde deleted the fix-empty-keyed-encoding branch February 20, 2019 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
No open projects
Vapor 3
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

3 participants