fix(core): update

This commit is contained in:
Philipp Kunz 2019-07-18 14:44:45 +02:00
parent 8eb777dd45
commit 1158b4ff99
3 changed files with 9 additions and 2 deletions

View File

@ -19,6 +19,13 @@ export class Worker {
constructor(workerManagerArg: WorkerManager) { constructor(workerManagerArg: WorkerManager) {
this.workerManager = workerManagerArg; this.workerManager = workerManagerArg;
} }
/**
* gets all routes for a worker
*/
public async getRoutes(){
const zones = await this.workerManager.cfAccount.listZones();
}
public setRoutes(routeArray: string[]) { public setRoutes(routeArray: string[]) {

View File

@ -3,7 +3,7 @@ import { CloudflareAccount } from './cloudflare.classes.account';
import { Worker } from './cloudflare.classes.worker'; import { Worker } from './cloudflare.classes.worker';
export class WorkerManager { export class WorkerManager {
private cfAccount: CloudflareAccount; public cfAccount: CloudflareAccount;
constructor(cfAccountArg: CloudflareAccount) { constructor(cfAccountArg: CloudflareAccount) {
this.cfAccount = cfAccountArg; this.cfAccount = cfAccountArg;

View File

@ -2,7 +2,7 @@ import * as plugins from './cloudflare.plugins';
import { CloudflareAccount } from './cloudflare.classes.account'; import { CloudflareAccount } from './cloudflare.classes.account';
export class ZoneManager { export class ZoneManager {
private cfAccount: CloudflareAccount; public cfAccount: CloudflareAccount;
public zoneName: string; public zoneName: string;
constructor(cfAccountArg: CloudflareAccount) { constructor(cfAccountArg: CloudflareAccount) {