(self, body=None)
| 2349 | return self._get_app(self.body) |
| 2350 | |
| 2351 | def _get_app(self, body=None): |
| 2352 | app = self._app |
| 2353 | if app is None: |
| 2354 | try: |
| 2355 | tasks = self.tasks.tasks # is a group |
| 2356 | except AttributeError: |
| 2357 | tasks = self.tasks |
| 2358 | if tasks: |
| 2359 | app = tasks[0]._app |
| 2360 | if app is None and body is not None: |
| 2361 | app = body._app |
| 2362 | return app if app is not None else current_app |
| 2363 | |
| 2364 | tasks = getitem_property('kwargs.header', 'Tasks in chord header.') |
| 2365 | body = getitem_property('kwargs.body', 'Body task of chord.') |
no outgoing calls