Fixed a bug where it throws an error when no device is connected