Skip to content

Commit 76254c7

Browse files
marcelstoerjknack
authored andcommitted
Fix parser example (jooby-project#1077)
1 parent 84f5363 commit 76254c7

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

doc/req.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ parser((type, ctx) -> {
132132
return ctx.param(values -> new MyType(values.get(0)));
133133
}
134134
// no luck! move to next converter
135-
return next.next();
135+
return ctx.next();
136136
});
137137

138138
get("/", req -> {

jooby/src/main/java/org/jooby/Parser.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,7 @@ interface Context extends Builder {
567567
* return ctx.param(values {@literal ->} new MyType(values.get(0)));
568568
* }
569569
* // no luck! move next
570-
* return next.next();
570+
* return ctx.next();
571571
* }
572572
* </pre>
573573
*
@@ -583,7 +583,7 @@ interface Context extends Builder {
583583
* .get(((ParameterizedType) toType.getType()).getActualTypeArguments()[0]);
584584
*
585585
* // Ask param converter to resolve the new/next type.
586-
* Object result = next.next(paramType);
586+
* Object result = ctx.next(paramType);
587587
* return new MyType(result);
588588
* }
589589
* // no luck! move next

0 commit comments

Comments
 (0)