Skip to content

Commit

Permalink
[CHORE] 앱 버전을 가져오는 함수 로직 수정
Browse files Browse the repository at this point in the history
packageInfo 는 null 이 될 수 없음
  • Loading branch information
easyhooon committed Mar 26, 2024
1 parent b75b693 commit 83623a9
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,7 @@ class SettingViewModel @Inject constructor(

fun getVersionInfo(context: Context): String {
val packageInfo: PackageInfo = context.packageManager.getPackageInfo(context.packageName, 0)
if (packageInfo != null) {
return packageInfo.versionName
} else {
return "버전 정보가 없습니다."
}
return packageInfo.versionName
}

fun deleteAccount() = intent {
Expand Down

0 comments on commit 83623a9

Please sign in to comment.