import { Injectable } from '@angular/core' ; import { Resolve , ActivatedRouteSnapshot } from '@angular/router' ; import { RequestsService } from "../../services/requests/requests.service" ; import { UsersService } from "../../services/users/users.service" ; @ Injectable ( ) export class RequestsResolve implements Resolve < any > { constructor ( private userService , private requestsService ) { } resolve ( route ) { return this . userService . getUserRequests ( ) ; } }