Переменная не обновляется после декларации lateinit, неспособная вернуться
Функция OnCreateView override fun onCreateView(inflater: LayoutInflater?, container: ViewGroup?, savedInstanceState: Bundle?): View? { super.onCreateView(inflater, container, savedInstanceState) val view1 = inflater?.inflate(R.layout.fragment_home, container, false) val recyclerview = view1!!.findViewById<RecyclerView>(R.id.recycler_view) recyclerview.layoutManager = LinearLayoutManager(this.activity) //val name3: Array<Articles> = recyclerview.adapter = CustomAdaptor(fetchJson()) return view1 } Функция Fetchjson fun fetchJson(): Array<Articles> { println("Attempting to fetch JSON") val url1 = "https://go-api-api.herokuapp.com/" //var a1 = […]