summaryrefslogtreecommitdiff
path: root/core/ref_ptr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/ref_ptr.cpp')
-rw-r--r--core/ref_ptr.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/ref_ptr.cpp b/core/ref_ptr.cpp
index c2128fd45d..4a27b523fb 100644
--- a/core/ref_ptr.cpp
+++ b/core/ref_ptr.cpp
@@ -3,7 +3,7 @@
/*************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
-/* http://www.godotengine.org */
+/* https://godotengine.org */
/*************************************************************************/
/* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */
/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */
@@ -69,7 +69,7 @@ RID RefPtr::get_rid() const {
Ref<Reference> *ref = reinterpret_cast<Ref<Reference> *>(&data[0]);
if (ref->is_null())
return RID();
- Resource *res = (*ref)->cast_to<Resource>();
+ Resource *res = Object::cast_to<Resource>(ref->ptr());
if (res)
return res->get_rid();
return RID();