title: How can i fix the error 'java.lang.IllegalStateException: RecyclerView must not be null'
body: <p>I have a recyclerView where I send data with my adapter but got the error</p>
  
  <blockquote>
    <p><code>RecyclerView must not be null</code></p>
  </blockquote>
  
  <p>code with my adpater:</p>
  
  <pre><code>class InWaitingFragment : Fragment() {
  
      private lateinit var adapter: FastItemAdapter&lt;BarterWaitingItem&gt;
  
      override fun onCreateView(
          inflater: LayoutInflater, container: ViewGroup?,
          savedInstanceState: Bundle?
  
      ): View? {
  
          println("CONTAINER:  " + container)
  
          val inflate: FrameLayout = inflater.inflate(R.layout.fragment_in_waiting, container, false) as FrameLayout
  
          adapter = FastItemAdapter&lt;BarterWaitingItem&gt;()
  
         waitingRecyclerView.layoutManager = LinearLayoutManager(this)
  
         waitingRecyclerView.adapter = adapter
  
          val retrofit = Retrofit.Builder()
              .baseUrl("http://10.93.182.95:8888")
              .addConverterFactory(GsonConverterFactory.create())
              .build()
  
          val service = retrofit.create(RequestManager::class.java)
  
          val action  = service.getPending()
  
  
          action.enqueue(object: Callback&lt;ArrayList&lt;GetBarterResponse&gt;&gt; {
              override fun onResponse(
                  call: Call&lt;ArrayList&lt;GetBarterResponse&gt;&gt;,
                  response: Response&lt;ArrayList&lt;GetBarterResponse&gt;&gt;
              ) {
                  val allBarter = response.body()
                  if(allBarter != null){
                      for (c in allBarter){
                          println("OBJET: ${c.buyer_object.title}")
                      }
  
                      println("ONRESPONSE En attente: " + response.body().toString())
                  }
              }
  
              override fun onFailure(call: Call&lt;ArrayList&lt;GetBarterResponse&gt;&gt;, t: Throwable) {
                  println("ONFAILURE En attente: " + t.toString())
              }
          })
  
          return inflate
      }
  
  
  }
  </code></pre>
  
  <p>got an error to on the this of <code>LinearLayoutManager(this)</code>, says:</p>
  
  <blockquote>
  <pre><code>`require:Context!
   Founds: InWaitingFragment
  </code></pre>
  </blockquote>