Update beagle-term/js/launcher.js

close serial port when window is closed