$ docker
This file contains 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
public void generateHashkey(){ | |
try { | |
PackageInfo info = getPackageManager().getPackageInfo( | |
"YOUR_PACKAGE_NAME", | |
PackageManager.GET_SIGNATURES); | |
for (Signature signature : info.signatures) { | |
MessageDigest md = MessageDigest.getInstance("SHA"); | |
md.update(signature.toByteArray()); | |
Log.d(Constants.TAG, "HASH BELOW"); |
People
:bowtie: |
😄 :smile: |
😆 :laughing: |
---|---|---|
😊 :blush: |
😃 :smiley: |
:relaxed: |
😏 :smirk: |
😍 :heart_eyes: |
😘 :kissing_heart: |
😚 :kissing_closed_eyes: |
😳 :flushed: |
😌 :relieved: |
😆 :satisfied: |
😁 :grin: |
😉 :wink: |
😜 :stuck_out_tongue_winking_eye: |
😝 :stuck_out_tongue_closed_eyes: |
😀 :grinning: |
😗 :kissing: |
😙 :kissing_smiling_eyes: |
😛 :stuck_out_tongue: |
This file contains 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
export const findByEmail = (email: string): Promise<User> => { | |
// Some Logic | |
} |
This file contains 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
import * as UserService from "./user.service"; | |
export const register = async (email: string, password: string): Promise<User> =>{ | |
const user = await UserService.findByEmail(email); | |
if(user){ | |
throw new Error("An account with this email already exists.") | |
} | |
//Continue Logic | |
} |
This file contains 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
<layer-list xmlns:android="http://schemas.android.com/apk/res/android"> | |
<item android:id="@android:id/background"> | |
<shape> | |
<corners android:radius="8dp"/> | |
<solid android:color="@color/gray"/> | |
</shape> | |
</item> | |
<item android:id="@android:id/progress" | |
android:top="1dp" |
This file contains 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
@ExperimentalCoroutinesApi | |
fun EditText.doAfterTextChanged(): Flow<CharSequence?> { | |
return callbackFlow<CharSequence?> { | |
val listener = object : TextWatcher { | |
override fun beforeTextChanged(s: CharSequence?, start: Int, count: Int, after: Int) = | |
Unit | |
override fun onTextChanged(s: CharSequence?, start: Int, before: Int, count: Int) = Unit | |
override fun afterTextChanged(s: Editable?) { | |
offer(s) |
This file contains 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
@ExperimentalCoroutinesApi | |
fun SearchView.doOnQueryTextChanged(): Flow<CharSequence?> { | |
return callbackFlow<CharSequence?> { | |
val listener = object : SearchView.OnQueryTextListener { | |
override fun onQueryTextSubmit(query: String?) = false | |
override fun onQueryTextChange(newText: String?): Boolean { | |
offer(newText) | |
return false | |
} |
This file contains 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
@Composable | |
fun ConverterScreen( | |
navController: NavController, | |
viewModel: ConverterViewModel | |
) { | |
val scaffoldState = rememberScaffoldState() | |
val viewState by viewModel.viewState.collectAsState() | |
val viewEffects by viewModel.viewEffects.collectAsState(initial = null) |
This file contains 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
class MainCoroutineRule : TestWatcher() { | |
private val testDispatcher = TestCoroutineDispatcher() | |
override fun starting(description: Description?) { | |
Dispatchers.setMain(testDispatcher) | |
} | |
fun setup(setupBody: () -> Unit){ | |
testDispatcher.pauseDispatcher() |
OlderNewer