Skip to content

Commit 1ee7a2a

Browse files
generatedunixname89002005287564mmissey
authored andcommitted
Reaping draft_killswitch_allow_nontextnodes
Reviewed By: kedromelon Differential Revision: D17204758 fbshipit-source-id: 406a4db6d467c18757db0e1d25a4a833365a7bd2
1 parent afc2ab9 commit 1ee7a2a

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

src/component/handlers/edit/editOnInput.js

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ const UserAgent = require('UserAgent');
2020

2121
const {notEmptyKey} = require('draftKeyUtils');
2222
const findAncestorOffsetKey = require('findAncestorOffsetKey');
23-
const gkx = require('gkx');
2423
const keyCommandPlainBackspace = require('keyCommandPlainBackspace');
2524
const nullthrows = require('nullthrows');
2625

@@ -68,20 +67,13 @@ function editOnInput(editor: DraftEditor, e: SyntheticInputEvent<>): void {
6867
const domSelection = global.getSelection();
6968

7069
const {anchorNode, isCollapsed} = domSelection;
71-
const isNotTextNode = anchorNode.nodeType !== Node.TEXT_NODE;
7270
const isNotTextOrElementNode =
7371
anchorNode.nodeType !== Node.TEXT_NODE &&
7472
anchorNode.nodeType !== Node.ELEMENT_NODE;
7573

76-
if (gkx('draft_killswitch_allow_nontextnodes')) {
77-
if (isNotTextNode) {
78-
return;
79-
}
80-
} else {
81-
if (isNotTextOrElementNode) {
82-
// TODO: (t16149272) figure out context for this change
83-
return;
84-
}
74+
if (isNotTextOrElementNode) {
75+
// TODO: (t16149272) figure out context for this change
76+
return;
8577
}
8678

8779
if (

0 commit comments

Comments
 (0)