blob: e16d406db88c0e48cbcb2e45ba3de4c1b5030499 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
|
import Operator from "../Operator";
import TabPresenter from "../../presenters/TabPresenter";
export default class SelectLastTabOperator implements Operator {
constructor(private readonly tabPresenter: TabPresenter) {}
async run(): Promise<void> {
const tabs = await this.tabPresenter.getAll();
return this.tabPresenter.select(tabs[tabs.length - 1].id as number);
}
}
|