summaryrefslogtreecommitdiffstats
path: root/src/shared
diff options
context:
space:
mode:
Diffstat (limited to 'src/shared')
-rw-r--r--src/shared/Builder.cpp2
-rw-r--r--src/shared/ResourceImpl.cpp5
2 files changed, 2 insertions, 5 deletions
diff --git a/src/shared/Builder.cpp b/src/shared/Builder.cpp
index f73b0e11..9da71a09 100644
--- a/src/shared/Builder.cpp
+++ b/src/shared/Builder.cpp
@@ -89,7 +89,7 @@ Builder::connect(SharedPtr<const GraphObject> object)
void
Builder::build_object(SharedPtr<const GraphObject> object)
{
- for (GraphObject::Variables::const_iterator i = object->variables().begin();
+ for (GraphObject::Properties::const_iterator i = object->variables().begin();
i != object->variables().end(); ++i)
_interface.set_variable(object->path(), i->first, i->second);
diff --git a/src/shared/ResourceImpl.cpp b/src/shared/ResourceImpl.cpp
index 4dd25602..10c57fbe 100644
--- a/src/shared/ResourceImpl.cpp
+++ b/src/shared/ResourceImpl.cpp
@@ -34,10 +34,7 @@ ResourceImpl::get_property(const std::string& uri) const
{
static const Raul::Atom nil;
Properties::const_iterator i = _properties.find(uri);
- if (i == _properties.end())
- return nil;
- else
- return i->second;
+ return (i != _properties.end()) ? i->second : nil;
}