fixing unloading issue causing crash on the pebble