Register tg:// scheme on initial launch.

This commit is contained in:
John Preston 2024-07-02 13:22:33 +04:00
parent 3947056654
commit 8cbeadc68a

View file

@ -261,9 +261,14 @@ void Application::run() {
refreshGlobalProxy(); // Depends on app settings being read.
if (const auto old = Local::oldSettingsVersion(); old < AppVersion) {
if (const auto old = Local::oldSettingsVersion()) {
if (old < AppVersion) {
InvokeQueued(this, [] { RegisterUrlScheme(); });
Platform::NewVersionLaunched(old);
}
} else {
// Initial launch.
InvokeQueued(this, [] { RegisterUrlScheme(); });
Platform::NewVersionLaunched(old);
}
if (cAutoStart() && !Platform::AutostartSupported()) {