Skip to content

Commit

Permalink
fix(deps): update dependency pubsub to ^0.28 (#1231)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenyumic authored and fhinkel committed Apr 3, 2019
1 parent da8b213 commit 6691244
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions appengine/pubsub/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ const messages = [];
const PUBSUB_VERIFICATION_TOKEN = process.env.PUBSUB_VERIFICATION_TOKEN;
const TOPIC = process.env.PUBSUB_TOPIC;

const publisher = pubsub.topic(TOPIC).publisher();
const topic = pubsub.topic(TOPIC);

// [START gae_flex_pubsub_index]
app.get('/', (req, res) => {
Expand All @@ -61,7 +61,7 @@ app.post('/', formBodyParser, async (req, res, next) => {

const data = Buffer.from(req.body.payload);
try {
const messageId = await publisher.publish(data);
const messageId = await topic.publish(data);
res.status(200).send(`Message ${messageId} sent.`);
} catch (error) {
next(error);
Expand Down
2 changes: 1 addition & 1 deletion appengine/pubsub/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"test": "repo-tools test app && mocha */*.test.js --timeout=30000 --exit"
},
"dependencies": {
"@google-cloud/pubsub": "^0.22.0",
"@google-cloud/pubsub": "^0.28.0",
"body-parser": "^1.18.3",
"express": "^4.16.3",
"pug": "^2.0.1",
Expand Down

0 comments on commit 6691244

Please sign in to comment.