Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix #25

Merged
merged 9 commits into from
Jan 30, 2025
Merged

fix #25

merged 9 commits into from
Jan 30, 2025

Conversation

asgothian
Copy link
Owner

No description provided.

const dev_block = $(this).parents('div.device');
const id = getDevId(dev_block);
const name = getDevName(dev_block);
toggleDebugDevice(id, name);

Check warning

Code scanning / CodeQL

Superfluous trailing arguments Warning

Superfluous argument passed to
function toggleDebugDevice
.
async function toggleDebugDevice(id) {
sendTo(namespace, 'setDeviceDebug', {id:id}, function (msg) {
sendTo(namespace, 'getDebugDevices', {}, function(msg) {
if (msg && typeof (msg.debugDevices == 'array')) {

Check warning

Code scanning / CodeQL

Useless conditional Warning

This expression always evaluates to true.

async function selectImageOverride(id) {
const dev = devices.find((d) => d._id == id);
let localImages = undefined;

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable localImages.
admin/admin.js Outdated

function getDevices() {
getCoordinatorInfo();
sendTo(namespace, 'getDebugDevices', {}, function(msg) {
if (msg && typeof (msg.debugDevices == 'array')) {

Check warning

Code scanning / CodeQL

Useless conditional Warning

This expression always evaluates to true.
excludes.forEach(id => {
// const b = devices.find((item) => item._id.contains(id));
const exclude_id = id.key;
const exclude_icon = id.value;

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable exclude_icon.
}

verifyDeviceName(id, name) {
const savedId = id.replace(`${this.adapter.namespace}.`, '');

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable savedId.
}
if (!devStates) {
if (has_debug) this.error(`ELEVATED IE2: no device states for device ${devId} type '${model}'`)
if (has_elevated_debug)
this.elevatedMessage(devId, `ELEVATED IE02: no device states for device ${devId} type '${model}'`, true)

Check notice

Code scanning / CodeQL

Semicolon insertion Note

Avoid automated semicolon insertion (96% of all statements in
the enclosing function
have an explicit semicolon).
@@ -622,6 +715,7 @@
for (const stateInd in states) {
const statedesc = states[stateInd];
let value;
let extra_value = undefined;

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable extra_value.
try {
this.warn(`Pinging '${ieeeAddr}' (${device.modelID})`)

Check notice

Code scanning / CodeQL

Semicolon insertion Note

Avoid automated semicolon insertion (95% of all statements in
the enclosing function
have an explicit semicolon).
await this.herdsman.stop();
}
catch (error) {
this.warn(`Starting zigbee-herdsman problem : ${error && error.message ? error.message : 'no error message'}`)

Check notice

Code scanning / CodeQL

Semicolon insertion Note

Avoid automated semicolon insertion (98% of all statements in
the enclosing function
have an explicit semicolon).
@asgothian asgothian merged commit 9c12225 into 1.11 Jan 30, 2025
2 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant