Skip to content

Commit 742e98d

Browse files
authored
Enable the secure flags only when it is not a debug build (#156)
1 parent 3afe54c commit 742e98d

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

app/src/main/kotlin/photos/network/MainActivity.kt

+6-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,12 @@ class MainActivity : ComponentActivity() {
5353

5454
WindowCompat.setDecorFitsSystemWindows(window, false)
5555

56-
window.setFlags(WindowManager.LayoutParams.FLAG_SECURE, WindowManager.LayoutParams.FLAG_SECURE)
56+
if (!BuildConfig.DEBUG) {
57+
window.setFlags(
58+
WindowManager.LayoutParams.FLAG_SECURE,
59+
WindowManager.LayoutParams.FLAG_SECURE,
60+
)
61+
}
5762

5863
setContent {
5964
PhotosApp(

0 commit comments

Comments
 (0)