From 4a6995be18b15de1834a39c8921a0e4109671bb6 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 3 Jun 2016 22:08:03 +0200 Subject: First draft to use webpack instead of systemjs --- client/app/friends/friend.service.ts | 31 ------------------------------- client/app/friends/index.ts | 1 - 2 files changed, 32 deletions(-) delete mode 100644 client/app/friends/friend.service.ts delete mode 100644 client/app/friends/index.ts (limited to 'client/app/friends') diff --git a/client/app/friends/friend.service.ts b/client/app/friends/friend.service.ts deleted file mode 100644 index d3684f08d..000000000 --- a/client/app/friends/friend.service.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Injectable } from '@angular/core'; -import { Http, Response } from '@angular/http'; -import { Observable } from 'rxjs/Rx'; - -import { AuthService } from '../shared/index'; - -@Injectable() -export class FriendService { - private static BASE_FRIEND_URL: string = '/api/v1/pods/'; - - constructor (private http: Http, private authService: AuthService) {} - - makeFriends() { - const headers = this.authService.getRequestHeader(); - return this.http.get(FriendService.BASE_FRIEND_URL + 'makefriends', { headers }) - .map(res => res.status) - .catch(this.handleError); - } - - quitFriends() { - const headers = this.authService.getRequestHeader(); - return this.http.get(FriendService.BASE_FRIEND_URL + 'quitfriends', { headers }) - .map(res => res.status) - .catch(this.handleError); - } - - private handleError (error: Response): Observable { - console.error(error); - return Observable.throw(error.json().error || 'Server error'); - } -} diff --git a/client/app/friends/index.ts b/client/app/friends/index.ts deleted file mode 100644 index 0adc256c4..000000000 --- a/client/app/friends/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './friend.service'; -- cgit v1.2.3