mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-06 22:40:14 -05:00
🐛 Fixed About modal dev experiments info in Settings (#19087)
refs https://ghost.slack.com/archives/C0568LN2CGJ/p1700617587979039 - Fixes an issue where dev experiments data shows up in the settings About modal while it's disabled. Now it will only shows that info when it's enabled.
This commit is contained in:
parent
e01c87800e
commit
8038c5854e
1 changed files with 5 additions and 4 deletions
|
@ -17,11 +17,12 @@ const AboutModal = NiceModal.create<RoutingModalProps>(({}) => {
|
|||
return date.getFullYear();
|
||||
}
|
||||
|
||||
function hasDeveloperExperiments():string {
|
||||
function hasDeveloperExperiments():boolean {
|
||||
if (config.enableDeveloperExperiments) {
|
||||
return 'Enabled';
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
return 'Disabled';
|
||||
}
|
||||
|
||||
function showSystemInfo() : boolean {
|
||||
|
@ -73,7 +74,7 @@ const AboutModal = NiceModal.create<RoutingModalProps>(({}) => {
|
|||
}
|
||||
{
|
||||
hasDeveloperExperiments() && (
|
||||
<div><strong>Developer experiments:</strong> {hasDeveloperExperiments()}</div>
|
||||
<div><strong>Developer experiments:</strong> Enabled</div>
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue