fix settings modal hiding on keypress
authorAndrew Karpow <andy@ndyk.de>
Tue, 4 Feb 2014 17:58:05 +0000 (18:58 +0100)
committerAndrew Karpow <andy@ndyk.de>
Sat, 8 Mar 2014 11:30:48 +0000 (12:30 +0100)
htdocs/js/mpd.js

index 60114da..13b59b8 100644 (file)
@@ -460,9 +460,10 @@ function getHost() {
     socket.send('MPD_API_GET_MPDHOST');
 
     function onEnter(event) {
-      if ( event.which == 13 )
+      if ( event.which == 13 ) {
         setHost();
         $('#settings').modal('hide');
+      }
     }
 
     $('#mpdhost').keypress(onEnter);