Skip to content

Commit

Permalink
Fix Analysis initialization to ensure proper Resource setup
Browse files Browse the repository at this point in the history
  • Loading branch information
vitorfdl authored Nov 28, 2024
1 parent 401d13c commit e8ddbd6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions analysis.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const dayjs = require("dayjs");
const your_variable = "your_variable"; //enter the variable from your device you would like in the report

// The function myAnalysis will run when you execute your analysis
async function myAnalysis(context) {
async function startAnalysis(context) {
// reads the values from the environment and saves it in the variable envVars
const envVars = Utils.envToJson(context.environment);

Expand Down Expand Up @@ -135,7 +135,7 @@ async function myAnalysis(context) {
});
}

module.exports = new Analysis(myAnalysis);
Analysis.use(startAnalysis);

// To run analysis on your machine (external)
// module.exports = new Analysis(myAnalysis, { token: "YOUR-TOKEN" });
// Analysis.use(myAnalysis, { token: "YOUR-TOKEN" });

0 comments on commit e8ddbd6

Please sign in to comment.