Skip to content

Commit

Permalink
Fix input files not respecting the disabled state
Browse files Browse the repository at this point in the history
  • Loading branch information
maxcnunes committed Jan 27, 2017
1 parent ab0d603 commit 88ed74d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/renderer/components/server-modal-form.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,12 @@ export default class ServerModalForm extends Component {
id="file.socketPath"
name="file.socketPath"
onChange={::this.handleChange}
style={{ display: 'none' }} />
style={{ display: 'none' }}
disabled={(
this.state.host ||
this.state.port ||
this.isFeatureDisabled('server:socketPath')
)} />
</label>
</div>
</div>
Expand Down Expand Up @@ -405,6 +410,7 @@ export default class ServerModalForm extends Component {
id="file.ssh.privateKey"
name="file.ssh.privateKey"
onChange={::this.handleChange}
disabled={(!isSSHChecked || ssh.password)}
style={{ display: 'none' }} />
</label>
</div>
Expand Down

0 comments on commit 88ed74d

Please sign in to comment.