From 9c34742d966abcdf39ed6e5a141ddfac5e066aaf Mon Sep 17 00:00:00 2001 From: "Harry T. Vennik" Date: Sat, 9 Dec 2017 16:34:31 +0100 Subject: [PATCH] Fix bug in `get` for arrays Fixes #34 --- source/ddbus/thin.d | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/ddbus/thin.d b/source/ddbus/thin.d index 1a3f9f4..e684ec3 100644 --- a/source/ddbus/thin.d +++ b/source/ddbus/thin.d @@ -432,7 +432,7 @@ struct DBusAny { if (is(T == const(DBusAny)[])) { enforce((type == 'a' && signature != "y") || type == 'r', new TypeMismatchException( "Cannot get a " ~ T.stringof ~ " from a DBusAny with" ~ " a value of DBus type '" ~ this.typeSig ~ "'.", - typeCode!T, type)); + 'a', type)); return array; } @@ -442,7 +442,7 @@ struct DBusAny { if (is(T == const(ubyte)[])) { enforce(type == 'a' && signature == "y", new TypeMismatchException( "Cannot get a " ~ T.stringof ~ " from a DBusAny with" ~ " a value of DBus type '" ~ this.typeSig ~ "'.", - typeCode!T, type)); + 'a', type)); return binaryData; }