PageSourceSearch

https://dirask.com/resources/libs_da/common_js/post_utils.js?v=22

js dirask.com collected 2026-10-02 06:52:30 UTC 839 bytes, 42 lines download raw bytes

1'use strict';
2
3window.PostUtils = {
4    coverHashtags: function(data)
5    {
6        var result = [ ];
7
8        for (var i = 0; i < data.length; ++i)
9        {
10            var item = {
11                hashtagCode: data[i]
12            };
13
14            result.push(item);
15        }
16
17        return result;
18    },
19    getLanguageName: function(data)
20    {
21        var code = data.postLanguageCode || data.postLanguage;
22
23        if (code)
24        {
25            var language = Languages.getEntry(code);
26
27            if (language)
28                return language.name;
29        }
30
31        return 'English';
32    },
33    getLanguageCode: function(data)
34    {
35        var code = data.postLanguageCode || data.postLanguage;
36
37        if (code)
38            return code.toUpperCase();
39
40        return 'EN';
41    }
42};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.