Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
node-sass
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
楚学文
node-sass
Commits
a130dae8
Commit
a130dae8
authored
Aug 19, 2015
by
Marcin Cieslak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cast received values to <v8::Object> once type confirmed
parent
bf9f6ec2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
factory.cpp
src/sass_types/factory.cpp
+2
-2
No files found.
src/sass_types/factory.cpp
View file @
a130dae8
...
...
@@ -60,10 +60,10 @@ namespace SassTypes
Value
*
Factory
::
unwrap
(
v8
::
Local
<
v8
::
Value
>
obj
)
{
// Todo: non-SassValue objects could easily fall under that condition, need to be more specific.
if
(
!
obj
->
IsObject
()
||
obj
->
ToObject
()
->
InternalFieldCount
()
!=
1
)
{
if
(
!
obj
->
IsObject
()
||
obj
.
As
<
v8
::
Object
>
()
->
InternalFieldCount
()
!=
1
)
{
throw
std
::
invalid_argument
(
"A SassValue object was expected."
);
}
return
static_cast
<
Value
*>
(
Nan
::
GetInternalFieldPointer
(
obj
->
ToObject
(),
0
));
return
static_cast
<
Value
*>
(
Nan
::
GetInternalFieldPointer
(
obj
.
As
<
v8
::
Object
>
(),
0
));
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment