import { User } from '@dvn/kimlik/api/models';
import { BaseModel } from './base-model';
import { Workspace } from './workspace';
export class WorkspaceOwnership extends BaseModel {
  static decode(json) {
    const item = Object.assign(Object.create(WorkspaceOwnership.prototype), json);
    if (item.user)
      item.user = User.decode(item.user);
    if (item.workspace)
      item.workspace = Workspace.decode(item.workspace);
    return item;
  }
}
