title: RxJava - How to get Single from nested method
body: <p>In my Presenter i have a method which gets some list from DataHolder:</p>
  
  <pre><code>disposable.add(dataHolder.getMonthOfAttractions(monthInAdvance)
              .subscribeOn(Schedulers.io())
              .observeOn(AndroidSchedulers.mainThread())
              .subscribeWith(new DisposableSingleObserver&lt;Map&lt;String, List&lt;Attraction&gt;&gt;&gt;() {
                  @Override
                  public void onSuccess(Map&lt;String, List&lt;Attraction&gt;&gt; stringListMap) {
  
                  }
  
                  @Override
                  public void onError(Throwable e) {
  
                  }
              }));
  </code></pre>
  
  <p>Then, in my DataHolder I'm checking if my list isn't null. If true, returns my list, if false it downloads this list from server : </p>
  
  <pre><code>public Single&lt;Map&lt;String, List&lt;Attraction&gt;&gt;&gt; getMonthOfAttractions(int monthInAdvance) {
      Map&lt;String, List&lt;Attraction&gt;&gt; monthOfAttractions = monthlyAttractionsMap.get(monthInAdvance);
      if (monthOfAttractions != null)
          return Single.fromCallable(() -&gt; monthOfAttractions);
      else
          return apiGetMonthOfAttractions(monthInAdvance);
  </code></pre>
  
  <p>The problem is with apiGetMonthOfAttractions method. I dont know how to correctly implement this method to return value to my Presenter.</p>
  
  <p>I've tried something like:</p>
  
  <pre><code>private Single&lt;Map&lt;String, List&lt;Attraction&gt;&gt;&gt; apiGetMonthOfAttractions(int monthInAdvance) {
      cnkRetrofitProvider.getApiInterface().getAttractions(monthInAdvance)
              .subscribeWith(new CnkApiObserver&lt;AttractionListResponse&gt;() {
                  @Override
                  public void onSucceeded(AttractionListResponse result) {
                      result.getMonthOfAttractions();
                  }
  
                  @Override
                  public void onFailed(Error error) {
                  }
              });
  }
  </code></pre>
  
  <p>But in this case i have "missing return statement" and I'm out of ideas how to implement it. I'm begging to learn RxJava, so be understanding. </p>
  
  <p>Please help :) </p>
  
  <p>EDIT:
  This is what how my Retrofit getAttractions() method looks like:</p>
  
  <pre><code>public interface CnkApiInterface {
  
  @GET("pl/front-api/{dateFrom}/{dateTo}")
  Single&lt;AttractionListResponse&gt; getAttractions(@Path("dateFrom") String dateFrom, @Path("dateTo") String dateTo);}
  </code></pre>