Fix regex

This commit is contained in:
GotPPay
2018-01-26 15:35:38 +01:00
parent bca71604fb
commit 2870695b25

View File

@@ -127,7 +127,7 @@ class IntentDetails extends Component {
if (e.length === INTENT_NAME_MAX_LENGTH) return; if (e.length === INTENT_NAME_MAX_LENGTH) return;
let newIntent = this.state.intent; let newIntent = this.state.intent;
//Allow question name with only letters, and with one character minimum //Allow question name with only letters, and with one character minimum
if (/^[a-z]+$/i.test(e)){ if (/^[a-z]*$/i.test(e)){
newIntent.intentName = e; newIntent.intentName = e;
} }
this.setState({intent: newIntent}); this.setState({intent: newIntent});