Bug fix for bluetooth