about summary refs log tree commit diff
path: root/app
diff options
context:
space:
mode:
authorOndřej Hruška <ondra@ondrovo.com>2018-01-06 19:58:04 +0100
committerOndřej Hruška <ondra@ondrovo.com>2018-01-06 19:58:04 +0100
commit9f29fd31ba3cdeb2f4551a662c68905e9a1a9e33 (patch)
tree2aff4c7b04057d543e06df965c6fac0686bbae0d /app
parent53caab0c0bff48e7b23bc3e8dd5505345a2f263a (diff)
fixed ctrl enter
Diffstat (limited to 'app')
-rw-r--r--app/javascript/flavours/glitch/features/composer/textarea/index.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/app/javascript/flavours/glitch/features/composer/textarea/index.js b/app/javascript/flavours/glitch/features/composer/textarea/index.js
index 0f5fd4d4d..6c2b8baa2 100644
--- a/app/javascript/flavours/glitch/features/composer/textarea/index.js
+++ b/app/javascript/flavours/glitch/features/composer/textarea/index.js
@@ -128,6 +128,11 @@ const handlers = {
       return;
     }
 
+    //  We submit the status on control/meta + enter.
+    if (onSubmit && e.keyCode === 13 && (e.ctrlKey || e.metaKey)) {
+      onSubmit();
+    }
+
     //  Switches over the pressed key.
     switch(e.key) {
 
@@ -157,11 +162,6 @@ const handlers = {
       }
       return;
     }
-
-    //  We submit the status on control/meta + enter.
-    if (onSubmit && e.keyCode === 13 && (e.ctrlKey || e.metaKey)) {
-      onSubmit();
-    }
   },
 
   //  When the escape key is released, we either close the suggestions