Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: lib/filterListener.js

Issue 29333245: Issue 3473 - patterns.ini is being saved on every filter hit after a while (Closed)
Patch Set: Created Jan. 6, 2016, 11:57 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/filterListener.js
===================================================================
--- a/lib/filterListener.js
+++ b/lib/filterListener.js
@@ -71,17 +71,20 @@ let FilterListener =
*/
setDirty: function(/**Integer*/ factor)
{
if (factor == 0 && isDirty > 0)
isDirty = 1;
else
isDirty += factor;
if (isDirty >= 1)
+ {
+ isDirty = 0;
FilterStorage.saveToDisk();
+ }
}
};
/**
* Observer listening to history purge actions.
* @class
*/
let HistoryPurgeObserver =
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld