Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
b-Nollet committed Sep 19, 2024
1 parent 31afffe commit 0846242
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions packages/xo-web/src/xo-app/home/host-item.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,11 @@ import { getXoaPlan, SOURCES } from '../../common/xoa-plans'
export default class HostItem extends Component {
state = {
isHostTimeConsistentWithXoaTime: true,
isPubKeyTooShort: false,
}

componentWillMount() {
this.props.isPubKeyTooShort.then(isPubKeyTooShort => this.setState({ isPubKeyTooShort }))
Promise.resolve(isHostTimeConsistentWithXoaTime(this.props.item)).then(value =>
this.setState({
isHostTimeConsistentWithXoaTime: value,
Expand Down Expand Up @@ -138,7 +140,7 @@ export default class HostItem extends Component {
() => this.state.isHostTimeConsistentWithXoaTime,
this._getAreHostsVersionsEqual,
() => this.props.state.hostsByPoolId[this.props.item.$pool],
() => this.props.isPubKeyTooShort,
() => this.state.isPubKeyTooShort,
(needsRestart, host, isMaintained, isHostTimeConsistentWithXoaTime, areHostsVersionsEqual, poolHosts, isPubKeyTooShort) => {
const alerts = []

Expand Down Expand Up @@ -205,12 +207,10 @@ export default class HostItem extends Component {
render: (
<span>
<Icon icon='alarm' /> {_('pubKeyTooShort')}
<span>
<ul>
<li>{_('longerCustomCertficate')}</li>
<li>{_('longerDefaultCertificate')}</li>
</ul>
</span>
<ul>
<li>{_('longerCustomCertficate')}</li>
<li>{_('longerDefaultCertificate')}</li>
</ul>
</span>
),
})
Expand Down

0 comments on commit 0846242

Please sign in to comment.