Skip to content

Commit f8d4c84

Browse files
committed
Fixing Sample GB issues
Bug: 28560299 Bug: 28563690 Change-Id: I825fb7b33f5875ccf2d6f8cb3d775b961d2603b8
1 parent 49c975e commit f8d4c84

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

auth/app/src/main/res/layout/activity_custom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
android:layout_height="wrap_content"
3232
android:ellipsize="end"
3333
android:maxLines="1"
34+
android:singleLine="true"
3435
android:text="@string/token_null" />
3536

3637
<TextView

storage/app/src/main/java/com/google/firebase/quickstart/firebasestorage/MainActivity.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
import android.content.Context;
2323
import android.content.Intent;
2424
import android.net.Uri;
25+
import android.os.Build;
2526
import android.os.Bundle;
2627
import android.os.Environment;
2728
import android.provider.MediaStore;
@@ -217,9 +218,12 @@ public void onFailure(@NonNull Exception exception) {
217218

218219
@AfterPermissionGranted(RC_STORAGE_PERMS)
219220
private void launchCamera() {
221+
Log.d(TAG, "launchCamera");
222+
220223
// Check that we have permission to read images from external storage.
221224
String perm = Manifest.permission.READ_EXTERNAL_STORAGE;
222-
if (!EasyPermissions.hasPermissions(this, perm)) {
225+
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M
226+
&& !EasyPermissions.hasPermissions(this, perm)) {
223227
EasyPermissions.requestPermissions(this, getString(R.string.rationale_storage),
224228
RC_STORAGE_PERMS, perm);
225229
return;

0 commit comments

Comments
 (0)