I have a service called from my home.ts page
import {Http} from '@angular/http';
import 'rxjs/add/operator/map';
import { Observable } from "rxjs/Observable";
export class HeritageService {
static get parameters() {
return [[Http]];
}
constructor(private http:Http) {
}
public searchMoviesWords(geo, text, start): Observable <any> {
var geoString = '';
if(!text.search('here')) {
geoString = '&geo=' + encodeURI(geo) +',10';
text = text.replace('here', '');
}
var url = 'https://...' + encodeURI(text) + geoString + '&page=' + start;
var response = this.http.get(url).map(res => res.json());
console.log(url);
return response;
}
public searchMoviesGeo(geo, start): Observable <any> {
var url = 'https://...' + encodeURI(geo) + ',10&page=' + start;
var response = this.http.get(url).map(res => res.json());
console.log(url);
return response;
}
}
Everything works great via ionic serve
however when coming to ionic build iOS
i get the error “Supplied parameters do not match any signature of call target.” The error from terminal indicates on this line: ngc: Error: Error at /Users/iantearle/Ionic/heritageApp/.tmp/pages/home/home.ngfactory.ts:69:33
that line is actually: this._HeritageService_0_4 = new import3.HeritageService();
What if anything am I doing wrong? I’ve checked the functions are calling the correct amount of parameters - I’ve even removed each function of the service class and the error still appears.