This file is indexed.

/usr/lib/python3/dist-packages/glances/outputs/static/js/services/plugins/glances_folders.js is in glances 2.7.1.1-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
glancesApp.service('GlancesPluginFolders', function() {
    var _pluginName = "folders";
    this.folders = [];

    this.setData = function(data, views) {
        data = data[_pluginName];
        this.folders = [];

        for (var i = 0; i < data.length; i++) {
            var folderData = data[i];

            var folder = {
                'path': folderData['path'],
                'size': folderData['size'],
                'careful': folderData['careful'],
                'warning': folderData['warning'],
                'critical': folderData['critical']
            };

            this.folders.push(folder);
        }
    };

    this.getDecoration = function(folder) {

        if (!Number.isInteger(folder.size)) {
            return;
        }

        if (folder.critical !== null && folder.size > (folder.critical * 1000000)) {
            return 'critical';
        } else if (folder.warning !== null && folder.size > (folder.warning * 1000000)) {
            return 'warning';
        } else if (folder.careful !== null && folder.size > (folder.careful * 1000000)) {
            return 'careful';
        }

        return 'ok';
    };
});