Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(quickstart): generator -> async #1650

Merged
merged 1 commit into from
Nov 13, 2017
Merged

Conversation

atian25
Copy link
Member

@atian25 atian25 commented Nov 13, 2017

Checklist
  • documentation is changed or added
  • commit message follows commit guidelines
Affected core subsystem(s)
Description of change

@codecov-io
Copy link

codecov-io commented Nov 13, 2017

Codecov Report

Merging #1650 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1650   +/-   ##
=======================================
  Coverage   99.57%   99.57%           
=======================================
  Files          29       29           
  Lines         712      712           
=======================================
  Hits          709      709           
  Misses          3        3

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 858c110...4d7deab. Read the comment docs.

@@ -349,14 +352,14 @@ that checks the User-Agent.
// app/middleware/robot.js
// options === app.config.robot
module.exports = (options, app) => {
return function* robotMiddleware(next) {
return async function robotMiddleware(next) {
Copy link
Member

Choose a reason for hiding this comment

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

async function (ctx, next) 下面的 this 都要改成 ctx

Copy link
Member Author

Choose a reason for hiding this comment

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

fixed

@@ -323,14 +327,14 @@ exports.relativeTime = time => moment(new Date(time * 1000)).fromNow();
// app/middleware/robot.js
// options === app.config.robot
module.exports = (options, app) => {
return function* robotMiddleware(next) {
return async function robotMiddleware(next) {
Copy link
Member

Choose a reason for hiding this comment

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

同上

@atian25 atian25 force-pushed the docs-2.x-quickstart branch 2 times, most recently from db21418 to b1decfb Compare November 13, 2017 03:42
@atian25 atian25 force-pushed the docs-2.x-quickstart branch from b1decfb to cb068e7 Compare November 13, 2017 03:43
@dead-horse dead-horse merged commit 4993ee8 into master Nov 13, 2017
@dead-horse dead-horse deleted the docs-2.x-quickstart branch November 13, 2017 04:09
popomore pushed a commit that referenced this pull request Nov 13, 2017
docs(quickstart): generator -> async (#1650)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants