Linux unitednationsplay.com 3.10.0-1160.45.1.el7.x86_64 #1 SMP Wed Oct 13 17:20:51 UTC 2021 x86_64
nginx/1.20.1
Server IP : 188.130.139.92 & Your IP : 3.140.201.179
Domains :
Cant Read [ /etc/named.conf ]
User : web
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
www /
unp_probe /
node_modules /
node-sass /
src /
Delete
Unzip
Name
Size
Permission
Date
Action
libsass
[ DIR ]
drwxr-xr-x
2021-02-04 21:24
sass_types
[ DIR ]
drwxr-xr-x
2021-02-04 21:24
.DS_Store
8
KB
-rw-r--r--
2018-04-24 15:53
binding.cpp
13.19
KB
-rw-r--r--
2018-08-09 12:53
callback_bridge.h
7
KB
-rw-r--r--
2018-08-09 12:53
create_string.cpp
446
B
-rw-r--r--
2018-08-09 12:53
create_string.h
124
B
-rw-r--r--
2018-08-09 12:53
custom_function_bridge.cpp
812
B
-rw-r--r--
2018-08-09 12:53
custom_function_bridge.h
532
B
-rw-r--r--
2018-08-09 12:53
custom_importer_bridge.cpp
3.37
KB
-rw-r--r--
2018-08-09 12:53
custom_importer_bridge.h
753
B
-rw-r--r--
2018-08-09 12:53
libsass.gyp
3.2
KB
-rw-r--r--
2018-07-08 11:24
sass_context_wrapper.cpp
1.72
KB
-rw-r--r--
2018-08-09 12:53
sass_context_wrapper.h
1.24
KB
-rw-r--r--
2018-08-09 12:53
Save
Rename
#include <nan.h> #include <stdexcept> #include "custom_importer_bridge.h" #include "create_string.h" SassImportList CustomImporterBridge::post_process_return_value(v8::Local<v8::Value> returned_value) const { SassImportList imports = 0; Nan::HandleScope scope; if (returned_value->IsArray()) { v8::Local<v8::Array> array = returned_value.As<v8::Array>(); imports = sass_make_import_list(array->Length()); for (size_t i = 0; i < array->Length(); ++i) { v8::Local<v8::Value> value = Nan::Get(array, static_cast<uint32_t>(i)).ToLocalChecked(); if (!value->IsObject()) { auto entry = sass_make_import_entry(0, 0, 0); sass_import_set_error(entry, "returned array must only contain object literals", -1, -1); continue; } v8::Local<v8::Object> object = value.As<v8::Object>(); if (value->IsNativeError()) { char* message = create_string(Nan::Get(object, Nan::New<v8::String>("message").ToLocalChecked())); imports[i] = sass_make_import_entry(0, 0, 0); sass_import_set_error(imports[i], message, -1, -1); free(message); } else { imports[i] = get_importer_entry(object); } } } else if (returned_value->IsNativeError()) { imports = sass_make_import_list(1); v8::Local<v8::Object> object = returned_value.As<v8::Object>(); char* message = create_string(Nan::Get(object, Nan::New<v8::String>("message").ToLocalChecked())); imports[0] = sass_make_import_entry(0, 0, 0); sass_import_set_error(imports[0], message, -1, -1); free(message); } else if (returned_value->IsObject()) { imports = sass_make_import_list(1); imports[0] = get_importer_entry(returned_value.As<v8::Object>()); } return imports; } Sass_Import* CustomImporterBridge::check_returned_string(Nan::MaybeLocal<v8::Value> value, const char *msg) const { v8::Local<v8::Value> checked; if (value.ToLocal(&checked)) { if (!checked->IsUndefined() && !checked->IsString()) { goto err; } else { return nullptr; } } err: auto entry = sass_make_import_entry(0, 0, 0); sass_import_set_error(entry, msg, -1, -1); return entry; } Sass_Import* CustomImporterBridge::get_importer_entry(const v8::Local<v8::Object>& object) const { auto returned_file = Nan::Get(object, Nan::New<v8::String>("file").ToLocalChecked()); auto returned_contents = Nan::Get(object, Nan::New<v8::String>("contents").ToLocalChecked()).ToLocalChecked(); auto returned_map = Nan::Get(object, Nan::New<v8::String>("map").ToLocalChecked()); Sass_Import *err; if ((err = check_returned_string(returned_file, "returned value of `file` must be a string"))) return err; if ((err = check_returned_string(returned_contents, "returned value of `contents` must be a string"))) return err; if ((err = check_returned_string(returned_map, "returned value of `returned_map` must be a string"))) return err; char* path = create_string(returned_file); char* contents = create_string(returned_contents); char* srcmap = create_string(returned_map); return sass_make_import_entry(path, contents, srcmap); } std::vector<v8::Local<v8::Value>> CustomImporterBridge::pre_process_args(std::vector<void*> in) const { std::vector<v8::Local<v8::Value>> out; for (void* ptr : in) { out.push_back(Nan::New<v8::String>((char const*)ptr).ToLocalChecked()); } return out; }