Update iwlist.js

This commit is contained in:
Aydoğan Karagöz 2019-09-11 16:59:05 +03:00 committed by GitHub
parent bc61dc2f02
commit 50090aecda
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -43,8 +43,8 @@ function parseOutput(str, callback) {
}
// Channel, an ugly thing to get it
else if (_.startsWith(line.trim(), 'Frequency:')) {
network.channel = parseInt(_.trim(line, ' )').split(/Channel/)[1], 10);
else if (_.startsWith(line.trim(), 'Channel:')) {
network.channel = parseInt(_.trim(line, ' )').split(/:/)[1]);
}
// Another ugly thing, the signal which can have different formats, even worse als