Last active
August 29, 2022 10:32
-
-
Save cp-hardik-p/b7dc4391d35b0857b180c54e6440ea55 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| suspend fun storeUserInfo(age: Int, name: String) { | |
| context.dataStore.edit { preferences -> | |
| preferences[USER_AGE_KEY] = age | |
| preferences[USER_NAME_KEY] = name | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment