From: Zeeshan Ali (Khattak) Date: Wed, 28 Jan 2009 12:32:47 +0000 (+0000) Subject: Remove some forgotten redundant code. X-Git-Tag: RYGEL_0_2_2~155 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f73afcc894ae816c13a627a17e121f3f6ec1188b;p=profile%2Fivi%2Frygel.git Remove some forgotten redundant code. svn path=/trunk/; revision=488 --- diff --git a/src/plugins/tracker/rygel-media-tracker.vala b/src/plugins/tracker/rygel-media-tracker.vala index 8ab07ee..08a900e 100644 --- a/src/plugins/tracker/rygel-media-tracker.vala +++ b/src/plugins/tracker/rygel-media-tracker.vala @@ -76,35 +76,23 @@ public class Rygel.MediaTracker : ContentDirectory { public override void add_children_metadata (DIDLLiteWriter didl_writer, BrowseArgs args) throws GLib.Error { - TrackerContainer container; - if (args.requested_count == 0) args.requested_count = MAX_REQUESTED_COUNT; - container = this.find_container_by_id (args.object_id); - if (container == null) - args.number_returned = 0; - else { - ArrayList children; - - children = this.get_children (args.object_id, - args.index, - args.requested_count, - out args.total_matches); + ArrayList children; - /* Iterate through all items */ - for (int i = 0; i < children.size; i++) { - children[i].serialize (didl_writer); - } + children = this.get_children (args.object_id, + args.index, + args.requested_count, + out args.total_matches); + args.number_returned = children.size; - args.number_returned = children.size; + /* Iterate through all items */ + for (int i = 0; i < children.size; i++) { + children[i].serialize (didl_writer); } - if (args.number_returned > 0) { - args.update_id = uint32.MAX; - } else { - throw new ContentDirectoryError.NO_SUCH_OBJECT ("No such object"); - } + args.update_id = uint32.MAX; } public override void add_metadata (DIDLLiteWriter didl_writer,