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 android.util.Log; | |
import com.google.gson.Gson; | |
import com.app.name.BuildConfig; | |
/** | |
* This class defines the Logger | |
*/ | |
public final class Logger { |
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
val storageRef = Firebase.storage.reference | |
fun uploadPhoto(photoUrl: Uri, onComplete: (downloadUrl: String?) -> Unit){ | |
val profilePhotosRef = storageRef.child("photos/${getPref().firebaseUuid}") | |
val metadata = storageMetadata { | |
contentType = "image/jpeg" | |
} | |
d { "uploadPhoto: $photoUrl" } | |
val photoFile = photoUrl | |
val uploadTask = profilePhotosRef.putFile(photoFile,metadata) |