20 lines
517 B
C++
20 lines
517 B
C++
#pragma once
|
|
|
|
#include <QString>
|
|
|
|
namespace UpdateClient
|
|
{
|
|
inline bool shouldApplyInitialStateValue(const QString& key,
|
|
bool storedValueExists,
|
|
const QString& storedValue,
|
|
const QString& initialValue)
|
|
{
|
|
if (!storedValueExists)
|
|
return true;
|
|
|
|
return key == QStringLiteral("license_key")
|
|
&& storedValue.trimmed().isEmpty()
|
|
&& !initialValue.trimmed().isEmpty();
|
|
}
|
|
}
|