Skip to content

Commit

Permalink
@stats use-case fix
Browse files Browse the repository at this point in the history
  • Loading branch information
endel committed Feb 7, 2020
1 parent 5064a36 commit 60e7211
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@colyseus/schema",
"version": "0.5.26",
"version": "0.5.27",
"description": "Schema-based binary serializer / de-serializer.",
"main": "lib/index.js",
"types": "lib/index.d.ts",
Expand Down
7 changes: 6 additions & 1 deletion src/codegen/parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,12 @@ function inspectNode(node: ts.Node, context: Context, decoratorName: string) {
const typeArgument = typeDecorator.arguments[0];
defineProperty(property, typeArgument);

} else {
} else if (
prop.expression.arguments &&
prop.expression.arguments[1] &&
prop.expression.expression.arguments &&
prop.expression.expression.arguments[0]
) {
/**
* Calling `type()` as a regular method
*/
Expand Down

0 comments on commit 60e7211

Please sign in to comment.