netdata should compare the saved version number with its repository,
because comparing the Git ID for the "ab-debian" branch makes no sense:
these commits aren't available in the official repository at all, and
therefore the update check would always trigger and never find the
correct changes on GitHub ...
This reverts commit
7647a12b03d31e90cc2edd1546132bc0be973766.
})
.done(function(data) {
data = data.replace(/(\r\n|\n|\r| |\t)/gm,"");
-
- var c = getNetdataCommitIdFromVersion();
- if(c !== null && data.length === 40 && data.substring(0, 7) !== c) {
- versionLog('Installed files commit id and internal netdata git commit id do not match');
- data = c;
+ if(data.length !== 40) {
+ var c = getNetdataCommitIdFromVersion();
+ if(c === null) versionLog('Cannot find the git commit id of netdata.');
+ callback(c);
}
-
- if(data.length >= 7) {
+ else {
versionLog('Installed git commit id of netdata is ' + data);
document.getElementById('netdataCommitId').innerHTML = data.substring(0, 7);
callback(data);