Skip to content

Conversation

@bajtos
Copy link
Member

@bajtos bajtos commented Feb 6, 2018

Explicitly cast path parameter "id" from string to number because the REST transport does not implement parameter coercion yet. See #750

This change removes the following warnings from npm test output:

WARNING: id property cannot be changed from 3 to 3 for model:Todo
in 'before save' operation hook

WARNING: id property cannot be changed from 3 to 3 for model:Todo
in 'loaded' operation hook

This pull request is an alternative to #941.

Checklist

  • npm test passes on your machine
  • New tests added or existing tests modified to cover all changes
  • Code conforms with the style guide
  • Related API Documentation was updated
  • Affected artifact templates in packages/cli were updated
  • Affected example projects in packages/example-* were updated

Explicitly cast path parameter "id" from string to number because the
REST transport does not implement parameter coercion yet.
See #750

This change removes the following warnings from `npm test` output:

    WARNING: id property cannot be changed from 3 to 3 for model:Todo
    in 'before save' operation hook

    WARNING: id property cannot be changed from 3 to 3 for model:Todo
    in 'loaded' operation hook
@kjdelisle kjdelisle force-pushed the fix/id-property-cannot-be-changed-warnings branch from d429770 to 563003a Compare February 7, 2018 21:53
@kjdelisle
Copy link
Contributor

I'm rebasing this PR and landing it if there are no complaints/failures.

@kjdelisle kjdelisle merged commit 86139f6 into master Feb 7, 2018
@kjdelisle kjdelisle deleted the fix/id-property-cannot-be-changed-warnings branch February 7, 2018 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants