If a browser was created close it first.
(self)
| 759 | return self.loop.run_in_executor(self.thread_pool, func) |
| 760 | |
| 761 | async def close(self): |
| 762 | """ If a browser was created close it first. """ |
| 763 | if hasattr(self, "_browser"): |
| 764 | await self._browser.close() |
| 765 | super().close() |
| 766 | |
| 767 | def run(self, *coros): |
| 768 | """ Pass in all the coroutines you want to run, it will wrap each one |