Skip to content

Commit

Permalink
fix: Null pointer when sACN was never received
Browse files Browse the repository at this point in the history
  • Loading branch information
schw4rzlicht committed Jun 14, 2020
1 parent efb525a commit bc30dd9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/permissions/SACNPermission.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export default class SACNPermission implements PermissionInstance {

if (sacn) {
let universeData = this.universeData.get(sacn.universe);
if (_.isInteger(universeData[sacn.channel - 1]) && universeData[sacn.channel - 1] < 255) {
if (universeData && _.isInteger(universeData[sacn.channel - 1]) && universeData[sacn.channel - 1] < 255) {
permissionCollector.denyPermission("sacn",
`@${runtimeInformation.userName}, ${runtimeInformation.config.sacn.lockMessage}`);
}
Expand Down

0 comments on commit bc30dd9

Please sign in to comment.