From: Andrew Chilton <andychilton@gmail.com>
Date: Fri, 3 Oct 2008 01:06:35 +0000 (+1300)
Subject: Fix up where these functions now live
X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=62237a66a0558904b805a7d32af424228ad97b0a;p=cil.git

Fix up where these functions now live
---

diff --git a/lib/CIL/Command/Am.pm b/lib/CIL/Command/Am.pm
index 1fbd749..dde1812 100644
--- a/lib/CIL/Command/Am.pm
+++ b/lib/CIL/Command/Am.pm
@@ -110,7 +110,7 @@ sub run {
         $issue->Summary( $subject );
         $issue->Status( 'New' );
         $issue->CreatedBy( $from );
-        $issue->AssignedTo( user($cil) );
+        $issue->AssignedTo( CIL::Utils->user($cil) );
         $issue->Inserted( $date );
         $issue->Updated( $date );
         $issue->Description( $body );
diff --git a/lib/CIL/Command/Attach.pm b/lib/CIL/Command/Attach.pm
index ed354c5..4124983 100644
--- a/lib/CIL/Command/Attach.pm
+++ b/lib/CIL/Command/Attach.pm
@@ -33,7 +33,7 @@ sub name { 'attach' }
 sub run {
     my ($self, $cil, undef, $issue_name, $filename) = @_;
 
-    my $issue = load_issue_fuzzy( $cil, $issue_name );
+    my $issue = CIL::Utils->load_issue_fuzzy( $cil, $issue_name );
 
     # check to see if the file exists
     unless ( -r $filename ) {
@@ -41,7 +41,7 @@ sub run {
     }
 
     my $basename = basename( $filename );
-    my $user = user($cil);
+    my $user = CIL::Utils->user($cil);
 
     my $add_attachment_text = <<"EOF";
 Filename    : $basename
diff --git a/lib/CIL/Command/Comment.pm b/lib/CIL/Command/Comment.pm
index c7a8cbb..d47f479 100644
--- a/lib/CIL/Command/Comment.pm
+++ b/lib/CIL/Command/Comment.pm
@@ -33,14 +33,14 @@ sub name { 'comment' }
 sub run {
     my ($self, $cil, undef, $issue_name) = @_;
 
-    my $issue = load_issue_fuzzy( $cil, $issue_name );
+    my $issue = CIL::Utils->load_issue_fuzzy( $cil, $issue_name );
 
     CIL::Utils->ensure_interactive();
 
     # create the new comment
     my $comment = CIL::Comment->new('tmpname');
     $comment->Issue( $issue->name );
-    $comment->CreatedBy( user($cil) );
+    $comment->CreatedBy( CIL::Utils->user($cil) );
     $comment->Description("Description ...");
 
     CIL::Utils->add_comment_loop($cil, undef, $issue, $comment);
diff --git a/lib/CIL/Command/Steal.pm b/lib/CIL/Command/Steal.pm
index 2d2a9bb..901926e 100644
--- a/lib/CIL/Command/Steal.pm
+++ b/lib/CIL/Command/Steal.pm
@@ -37,7 +37,7 @@ sub run {
     my $issue = CIL::Utils->load_issue_fuzzy( $cil, $issue_name );
 
     # set the AssignedTo for this issue to you (because you're stealing it)
-    $issue->AssignedTo( user($cil) );
+    $issue->AssignedTo( CIL::Utils->user($cil) );
     $issue->save($cil);
 
     CIL::Utils->display_issue($cil, $issue);