diff --git a/Message.pm b/Message.pm index f50887a..f5bd524 100644 --- a/Message.pm +++ b/Message.pm @@ -92,9 +92,13 @@ sub get_transports { ## @method $ load_transport_module($args) -# Attempt to load an create an instance of a Message::Transport module. +# Attempt to load an create an instance of a Message::Transport module. Valid arguments +# are: # -# @param modulename The name of the transport module to load. +# - id, the ID of the transport to load. +# - name, the name of the transport to laod. +# +# @param args A hash or arguments to define the module to load. # @return A reference to an instance of the requested transport module on success, # undef on error. sub load_transport_module { diff --git a/Message/Queue.pm b/Message/Queue.pm index 231773b..b804946 100644 --- a/Message/Queue.pm +++ b/Message/Queue.pm @@ -359,7 +359,7 @@ sub deliver_queue { if(scalar(@{$messages})) { # Load the transport... - $transport -> {"module"} = $self -> load_transport_module($transport -> {"id"}) + $transport -> {"module"} = $self -> load_transport_module(id => $transport -> {"id"}) or return $self -> self_error("Transport loading failed: ".$self -> {"errstr"}); # Try to deliver each sendable message