No adapter attached; skipping layout [duplicate]

You didn’t attach the adapter because you create it after you try to attach it:

mRecyclerView.setAdapter(mAdapter); // Here, mAdapter is null
mAdapter = new CountryAdapter(CountryManager.getInstance().getCountries(), R.layout.card_layout, getActivity());

Leave a Comment