Skip to content

Expand literals by default#8

Open
tpluscode wants to merge 10 commits into
masterfrom
expand-literals
Open

Expand literals by default#8
tpluscode wants to merge 10 commits into
masterfrom
expand-literals

Conversation

@tpluscode

@tpluscode tpluscode commented Jan 12, 2017

Copy link
Copy Markdown
Contributor

fixes #3
fixes #9

else
{
var valueString = JsonConvert.ToString(value);
writer.WriteValue(valueString.Trim('"')); // for the weirdest of reasons, DateTime is double-quoted

@tpluscode tpluscode Jan 12, 2017

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@asbjornu JsonConvert produces quoted DateTime like "2016-01-03T00:00:00". any idea why this is happening?

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hm, that's weird. We do quite an extensive customisation of the JSON serialisation in Pomona, please have a look at that if you dare. 😄 I can give it a whack when time allows, which I won't have for a few weeks. 😕

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Uh, it's just me being foolish. The date is in quotes because that is a date is represented in JSON as string. Numbers aren't so they aren't in quotes. Same with bool

@codecov-io

codecov-io commented Jan 12, 2017

Copy link
Copy Markdown

Current coverage is 89.09% (diff: 88.00%)

Merging #8 into master will decrease coverage by 0.28%

@@             master         #8   diff @@
==========================================
  Files            32         33     +1   
  Lines           386        431    +45   
  Methods          56         78    +22   
  Messages          0          0          
  Branches         59         65     +6   
==========================================
+ Hits            345        384    +39   
- Misses           29         31     +2   
- Partials         12         16     +4   

Powered by Codecov. Last update 99415c6...665dab1

@tpluscode tpluscode self-assigned this Jan 14, 2017
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.

[Type] annotation for properties Adding datatype explicitly

3 participants