From ffde9d0bc098b29d243e6c606e3b9cba2bf7c692 Mon Sep 17 00:00:00 2001 From: Nicolas Garnier Date: Tue, 31 Jan 2017 20:56:31 +0100 Subject: [PATCH] Update the uuid sample for cross-product consistency See cl/145830521 for explanations. --- functions/uuid/index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/functions/uuid/index.js b/functions/uuid/index.js index 355c8f6625..3ac049d45d 100644 --- a/functions/uuid/index.js +++ b/functions/uuid/index.js @@ -18,7 +18,8 @@ // [START functions_uuid] const uuid = require('uuid'); -exports.uuid = function (event, callback) { - callback(null, uuid.v4()); +// Return a newly generated UUID in the HTTP response. +exports.getUuid = function (req, res) { + res.send(uuid.v4()); }; // [END functions_uuid]