projects
/
app.mailtrimmer
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
539917e
)
src/strip.vala
author
Alan Knowles
<alan@roojs.com>
Thu, 24 May 2018 08:58:37 +0000
(16:58 +0800)
committer
Alan Knowles
<alan@roojs.com>
Thu, 24 May 2018 08:58:37 +0000
(16:58 +0800)
src/strip.vala
patch
|
blob
|
history
diff --git
a/src/strip.vala
b/src/strip.vala
index
be9c1c1
..
2820a0f
100644
(file)
--- a/
src/strip.vala
+++ b/
src/strip.vala
@@
-871,6
+871,14
@@
public class Strip : GLib.Object {
var month = subpath.length > 5 ? int.parse(subpath.substring(6,2)) : 0; // "/2000/12"
var day = subpath.length > 8 ? int.parse(subpath.substring(9,2)) : 0; // "/2000/12/01"
+ var oldest = new DateTime.now_local();
+ oldest = oldest.add_months(-1 * StripApplication.opt_age_oldest);
+ if (year < oldest.get_year()) {
+ return;
+ }
+ if (year == oldest.get_year() && month < oldest.get_month()) {
+ return;
+ }