函数返回未定义的Firebase Ionic 5

时间:2020-08-11 04:57:44

标签: firebase ionic-framework

我试图在Firebase中实现功能计划,但此功能返回未定义

函数返回了未定义的预期承诺或值

export const teste = functions.database.ref('teste/{id}/original').onCreate((snapshot, context) => {

const original = snapshot.val();

if(original == '1') {
    functions.logger.info('VALOR ', context.params.id,  original);

    functions.pubsub.schedule('every 1 minutes')
        .timeZone('America/Sao_Paulo')
        .onRun(() => {
            // snapshot.ref.parent?.child('power').set(0);
            console.log("PASSANDO POR AQUI");
            return null;
        });
   }

});

0 个答案:

没有答案