PageSourceSearch

https://esora-law.com/wp-content/plugins/booking-package/js/Error.js?ver=1.7.28&date=1790323414

js esora-law.com collected 2026-09-25 08:03:44 UTC 4,808 bytes, 169 lines download raw bytes

1    function scriptError(data, dictionary, msg, url, line, col, error, front_end) {
2        
3        if (data == null) {
4            
5            return null;
6            
7        }
8        this._data = data;
9        this._dictionary = dictionary;
10        this._msg = msg;
11        this._url = url;
12        this._line = line;
13        this._col = col;
14        this._error = error;
15        this._function = {};
16        this._responseText = null;
17        this._front_end = front_end;
18        this._plugin_name = null;
19        this._wp_rest_nonce = null;
20        if (data.wp_rest_nonce != null) {
21            
22            this._wp_rest_nonce = data.wp_rest_nonce;
23            
24        }
25        
26        var locale = 'en_US';
27        if (data != null && data.locale != null) {
28            
29            locale = data.locale;
30            
31        }
32        
33        if (data != null && data.plugin_name != null) {
34            
35            this._plugin_name = data.plugin_name;
36            
37        }
38        
39        this._i18n = new I18n(locale);
40        this._i18n.setDictionary(dictionary);
41        
42    }
43    
44    scriptError.prototype.setResponseText = function(responseText) {
45        
46        this._responseText = responseText;
47        
48    }
49    
50    scriptError.prototype.getResponseText = function() {
51        
52        return this._responseText;
53        
54    }
55    
56    scriptError.prototype.setFunction = function(object) {
57        
58        this._function = object;
59        
60    }
61    
62    scriptError.prototype.send = function() {
63        
64        var object = this;
65        var javascriptFileslist = this._data.javascriptFileslist;
66        if (this._error == null) {
67            
68            this._error = {stack: null};
69            
70        }
71        
72        var parser = null;
73        var file = "";
74        if (this._url.length > 0) {
75            
76            parser = new URL(this._url);
77            file = parser.pathname.split('/').pop();
78            var bool = false;
79            for (var i = 0; i < javascriptFileslist.length; i++) {
80                
81                if(javascriptFileslist[i] == file){
82                    
83                    bool = true;
84                    break;
85                    
86                }
87                
88            }
89            
90            if (bool == false) {
91                
92                return {status: "error", message: "no file"};
93                
94            }
95            
96        }
97        
98        var values = JSON.stringify(this._function.post);
99        
100        if (parseInt(this._data.javascriptSyntaxErrorNotification) == 1) {
101            
102            var post = {
103                mode: 'scriptError', 
104                type: 'JavaScript',
105                file: file,
106                nonce: this._data.nonce, 
107                booking_package_nonce: this._data.nonce, 
108                action: this._data.action, 
109                msg: this._msg, 
110                url: this._url, 
111                line: this._line, 
112                col: this._col, 
113                error: this._error.stack,
114                version: window.navigator.appVersion,
115                code: window.navigator.appCodeName,
116                browser: window.navigator.userAgent,
117                name: this._function.name,
118                values: values,
119                source: '',
120                page: window.location.href,
121            };
122            
123            if (this._wp_rest_nonce != null) {
124                
125                post.booking_package_wp_rest_nonce = this._wp_rest_nonce;
126                
127            }
128            
129            if (this._plugin_name != null) {
130                
131                post.plugin_name = this._plugin_name;
132                
133            }
134            
135            var responseText = object.getResponseText();
136            if (typeof responseText == 'string') {
137                
138                post.responseText = responseText;
139                
140            }
141            
142            var xmlHttp = new Booking_App_XMLHttp(object._data.url, post, 0, function(response){
143                
144                object.setResponseText(null);
145                
146            });
147            /**
148            fetch(this._url).then(response => response.text()).then(function (text) {
149                    
150                    var lines = text.split("\n");
151                    post.source = lines[object._line - 1];
152                    console.error(post.source);
153                    var xmlHttp = new Booking_App_XMLHttp(object._data.url, post, 0, function(response){
154                        
155                        object.setResponseText(null);
156                        
157                    });
158                    
159                }
160            );
161            **/
162            
163        } else {
164            
165        }
166        
167    }
168    
169    

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.