I have this method and I would like to return true/false from it, but I am getting this error: A function whose declared type is neither 'void' nor 'any' must return a value.
  public isLoggedIn(): boolean {
    const url = `${this.endPoint}/me`;
    this.http.get<any>(url).subscribe(
      () => {
        return true;
      },
      () => {
        return false;
      }
    );
  }
 
     
     
    