Skip to content

Commit 25ab7e5

Browse files
committed
Merge commit 'd7f782cfb285762522543939db7e52ab2088f558' into HEAD
2 parents 67493fc + d7f782c commit 25ab7e5

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎samples-android/minimalist/jni/StateManager.cpp‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,13 +120,15 @@ void StateManager::InitServices(
120120
.SetLogging(gpg::DEFAULT_ON_LOG, gpg::LogLevel::VERBOSE)
121121
.SetOnAuthActionStarted([started_callback](gpg::AuthOperation op) {
122122
is_auth_in_progress_ = true;
123-
started_callback(op);
123+
if (started_callback != nullptr)
124+
started_callback(op);
124125
})
125126
.SetOnAuthActionFinished([finished_callback](gpg::AuthOperation op,
126127
gpg::AuthStatus status) {
127128
LOGI("Sign in finished with a result of %d", status);
128129
is_auth_in_progress_ = false;
129-
finished_callback(op, status);
130+
if (finished_callback != nullptr)
131+
finished_callback(op, status);
130132
LOGI("Fetching all blocking");
131133
gpg::AchievementManager::FetchAllResponse fetchResponse = game_services_->Achievements().FetchAllBlocking(std::chrono::milliseconds(1000));
132134
LOGI("--------------------------------------------------------------");

0 commit comments

Comments
 (0)