mirror of
https://github.com/tbabej/taskwiki.git
synced 2025-08-19 15:53:07 +02:00
SelectedTasks: Search for relevant TW after resetting the cache
This commit is contained in:
parent
342359f482
commit
56d4efae67
1 changed files with 3 additions and 2 deletions
|
@ -63,11 +63,12 @@ class WholeBuffer(object):
|
||||||
|
|
||||||
class SelectedTasks(object):
|
class SelectedTasks(object):
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.tw = cache.get_relevant_tw()
|
|
||||||
|
|
||||||
# Reset cache, otherwise old line content may be used
|
# Reset cache, otherwise old line content may be used
|
||||||
cache.reset()
|
cache.reset()
|
||||||
|
|
||||||
|
# Find relevant TaskWarrior instance
|
||||||
|
self.tw = cache.get_relevant_tw()
|
||||||
|
|
||||||
# Load the current tasks
|
# Load the current tasks
|
||||||
range_tasks = [cache.vwtask[i] for i in util.selected_line_numbers()]
|
range_tasks = [cache.vwtask[i] for i in util.selected_line_numbers()]
|
||||||
self.tasks = [t for t in range_tasks if t is not None]
|
self.tasks = [t for t in range_tasks if t is not None]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue