I am very new to this, I am using the sample ClassicKotlin from Android repository. There is a "media-feed.json" file in the asset which I would like to move it to a remote location instead of local file. Here is what I am changing . Part of the code is this now: the file name is :"TvMediaSynchronizer.kt"
/** Fetches the metadata feed from our assets folder and parses its metadata */
private fun parseMediaFeed(context: Context): FeedParseResult {
// Reads JSON input into a JSONArray
// We are using a local file, in your app you most likely will be using a remote URL
val stream = context.resources.assets.open("**media-feed.json**")
val data = JSONObject(
String(stream.readBytes(), StandardCharsets.UTF_8))
Instead of "media-feed.json" I typed "**https://sample.com/uploads/media-feed.json**"