Skip to content

Commit

Permalink
Merge pull request #15 from sandeepmistry/propertyname
Browse files Browse the repository at this point in the history
Pass in ifaceName for property get
  • Loading branch information
sidorares committed Apr 14, 2013
2 parents 1b9ef80 + 07b09f4 commit e3b487e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/introspect.js
Expand Up @@ -81,7 +81,7 @@ module.exports = function(obj, callback) {
console.log(' property: ', property);
// get = function(err, result) {}
//TODO: move up
function addReadProp(iface, propName, property) {
function addReadProp(iface, ifName, propName, property) {
Object.defineProperty(iface, propName, {
get: function() {
return function(callback) {
Expand All @@ -91,7 +91,7 @@ module.exports = function(obj, callback) {
'interface': 'org.freedesktop.DBus.Properties',
member: 'Get',
signature: 'ss',
body: [ifaceName, propName]
body: [ifName, propName]
}, function(err, val) {
if (err) callback(err);
var signature = val[0];
Expand All @@ -108,7 +108,7 @@ module.exports = function(obj, callback) {
}
});
}
addReadProp(currentIface, name, property);
addReadProp(currentIface, ifaceName, name, property);
}
for (s=0; iface.signal && s < iface.signal.length; ++s)
{
Expand Down

0 comments on commit e3b487e

Please sign in to comment.