Skip to content

Prevent whitespace branch names - #1298

Merged
niik merged 4 commits into
masterfrom
whitespace-strikes-again
Apr 27, 2017
Merged

niik merged 4 commits into
masterfrom
whitespace-strikes-again

Conversation

@iAmWillShepherd

Copy link
Copy Markdown
Contributor

Fixes #1288

I also added a warning for when the user attempts to name something along the lines of .

@iAmWillShepherd iAmWillShepherd added the ready-for-review Pull Requests that are ready to be reviewed by the maintainers label Apr 25, 2017
@niik niik self-assigned this Apr 26, 2017
Comment thread app/src/ui/create-branch/index.tsx Outdated
</Row>
)
private renderWarning() {
if (/^\s*$/.test(this.state.proposedName)) {

This comment was marked as spam.

Comment thread app/src/ui/create-branch/index.tsx Outdated
private renderWarning() {
if (/^\s*$/.test(this.state.proposedName)) {
return (
<Row className='warning-helper-text'>

This comment was marked as spam.

@iAmWillShepherd

Copy link
Copy Markdown
Contributor Author

💯

Comment thread app/src/ui/create-branch/index.tsx Outdated
if (this.state.proposedName === this.state.sanitizedName) { return null }
private renderWarning() {
if (/^\s+$/.test(this.state.proposedName)) {
return this.renderWarningMessage(' Branch name cannot be empty')

This comment was marked as spam.

@niik
niik merged commit 41f16c2 into master Apr 27, 2017
@niik
niik deleted the whitespace-strikes-again branch April 27, 2017 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-review Pull Requests that are ready to be reviewed by the maintainers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants