Skip to content

Fix tm_downloaded init when tied file not set or missing #69

@pyroscope

Description

@pyroscope

method.insert = pyro._tm_downloaded_stat, simple|private,\
"execute.capture=sh,-c,\"echo -n \$(stat -c %Y \\\"$1\\\")\",getDownloadedDate,(d.tied_to_file)"
method.insert = pyro._tm_downloaded_init, simple|private,\
"d.custom.set=tm_downloaded,(cat,(pyro._tm_downloaded_stat)); d.save_resume="

Add an if/branch and return system.time for untied items, or else :

method.insert = pyro._tm_downloaded_stat, simple|private,\ 
     "execute.capture=sh, -c , \
        \"echo -n \$(stat -c %Y \\\"$1\\\" 2>/dev/null) || echo -n \$(date +'%s')\", \
        getDownloadedDate, (d.tied_to_file)" 

Metadata

Metadata

Assignees

Labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions