From 9ee11654a6fadee2fb605d29e0a877cc1224c1a4 Mon Sep 17 00:00:00 2001 From: veeck Date: Thu, 2 Sep 2021 20:35:43 +0200 Subject: [PATCH] Update jsdocs --- modules/default/weather/providers/ukmetoffice.js | 6 +++--- modules/default/weather/weatherobject.js | 9 +++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/modules/default/weather/providers/ukmetoffice.js b/modules/default/weather/providers/ukmetoffice.js index 9166599a..158592bd 100755 --- a/modules/default/weather/providers/ukmetoffice.js +++ b/modules/default/weather/providers/ukmetoffice.js @@ -232,16 +232,16 @@ WeatherProvider.register("ukmetoffice", { return windCardinals.hasOwnProperty(windDirection) ? windCardinals[windDirection] : null; }, - /* + /** * Generates an url with api parameters based on the config. * - * return String - URL params. + * @param {string} forecastType daily or 3hourly forecast + * @returns {string} url */ getParams(forecastType) { let params = "?"; params += "res=" + forecastType; params += "&key=" + this.config.apiKey; - return params; } }); diff --git a/modules/default/weather/weatherobject.js b/modules/default/weather/weatherobject.js index 2d08f028..56eeeeee 100755 --- a/modules/default/weather/weatherobject.js +++ b/modules/default/weather/weatherobject.js @@ -13,11 +13,12 @@ */ class WeatherObject { /** + * Constructor for a WeatherObject * - * @param units - * @param tempUnits - * @param windUnits - * @param useKmh + * @param {string} units what units to use, "imperial" or "metric" + * @param {string} tempUnits what tempunits to use + * @param {string} windUnits what windunits to use + * @param {boolean} useKmh use kmh if true, mps if false */ constructor(units, tempUnits, windUnits, useKmh) { this.units = units;