Skip to content

Instantly share code, notes, and snippets.

@JWPapi
Created September 25, 2020 21:20
betSchema.virtual('toWin').get(function() {
return Number(this.backing/this.odds + this.backing/this.odds/this.odds).toFixed(2)
})
!==
betSchema.virtual('toWin').get(() => Number(this.backing/this.odds + this.backing/this.odds/this.odds).toFixed(2))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment