[Rt-commit] rt branch, 4.2/untabify, created. rt-4.1.5-262-g0727395

Alex Vandiver alexmv at bestpractical.com
Mon Jan 14 20:30:52 EST 2013


The branch, 4.2/untabify has been created
        at  07273951d61a15a049316d1ffbb384e060f87226 (commit)

- Log -----------------------------------------------------------------
commit 785dc2e37d265de7f5422551e6c9ff6d3558c44d
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Mon Jan 14 20:20:36 2013 -0500

    Remove hard tab characters wherever possible
    
    For historical reasons, many parts of the RT code intermix hard tabs and
    siace-based indentation.  This commit does not attempt to standardize
    indentation, merely the horrid intermixing of hard tabs and spaces.
    
    A few hard tabs remain in t/mail/mime_encoding.t and t/mail/outlook.t,
    as the tabs are within strings representing test data; they also remain
    in third-party source.
    
    Best viewed with the -w option to `git diff`.

diff --git a/bin/rt-crontool.in b/bin/rt-crontool.in
index 4ab60b3..91e9582 100644
--- a/bin/rt-crontool.in
+++ b/bin/rt-crontool.in
@@ -305,37 +305,37 @@ sub help {
       . "\n";
     print loc("It takes several arguments:") . "\n\n";
 
-    print "	"
+    print "        "
       . loc( "[_1] - Specify the search module you want to use", "--search" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - An argument to pass to [_2]", "--search-arg", "--search" )
       . "\n";
 
-    print "	"
+    print "        "
       . loc( "[_1] - Specify the condition module you want to use", "--condition" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - An argument to pass to [_2]", "--condition-arg", "--condition" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - Specify the action module you want to use", "--action" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - An argument to pass to [_2]", "--action-arg", "--action" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - Specify name or id of template(s) you want to use", "--template" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - Specify if you want to use either 'first', 'last' or 'all' transactions", "--transaction" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - Specify the comma separated list of transactions' types you want to use", "--transaction-type" )
       . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - Adjust LogToScreen config option", "--log" ) . "\n";
-    print "	"
+    print "        "
       . loc( "[_1] - Output status updates to STDOUT", "--verbose" ) . "\n";
     print "\n";
     print "\n";
diff --git a/devel/tools/extract-message-catalog b/devel/tools/extract-message-catalog
index cd28d92..826743f 100755
--- a/devel/tools/extract-message-catalog
+++ b/devel/tools/extract-message-catalog
@@ -194,8 +194,8 @@ sub extract_strings_from_code {
             next;
         }
         $str = substr($str, 1, -1);
-	$str =~ s/\\'/\'/g;
-	push @{ $FILECAT{$str} }, [ $filename, $line, '' ];
+        $str =~ s/\\'/\'/g;
+        push @{ $FILECAT{$str} }, [ $filename, $line, '' ];
     }
 
     # Comment-based qw mark: "qw(...)" # loc_qw
@@ -223,8 +223,8 @@ sub extract_strings_from_code {
             warn "Couldn't process loc_left_pair at $filename:$line";
             next;
         }
-	$key  =~ s/\\'/\'/g;
-	push @{ $FILECAT{$key} }, [ $filename, $line, '' ];
+        $key  =~ s/\\'/\'/g;
+        push @{ $FILECAT{$key} }, [ $filename, $line, '' ];
     }
 
     # Comment-based pair mark: "..." => "..." # loc_pair
@@ -237,11 +237,11 @@ sub extract_strings_from_code {
             warn "Couldn't process loc_pair at $filename:$line";
             next;
         }
-	$val = substr($val, 1, -1);
-	$key  =~ s/\\'/\'/g;
-	$val  =~ s/\\'/\'/g;
-	push @{ $FILECAT{$key} }, [ $filename, $line, '' ];
-	push @{ $FILECAT{$val} }, [ $filename, $line, '' ];
+        $val = substr($val, 1, -1);
+        $key  =~ s/\\'/\'/g;
+        $val  =~ s/\\'/\'/g;
+        push @{ $FILECAT{$key} }, [ $filename, $line, '' ];
+        push @{ $FILECAT{$val} }, [ $filename, $line, '' ];
     }
 
     close (_);
@@ -259,8 +259,8 @@ sub update {
     my $out = '';
 
     unless (!-e $file or -w $file) {
-	warn "Can't write to $lang, skipping...\n";
-	return;
+        warn "Can't write to $lang, skipping...\n";
+        return;
     }
 
     print "Updating $lang...\n";
diff --git a/devel/tools/rt-apache b/devel/tools/rt-apache
index b78933a..fffde20 100755
--- a/devel/tools/rt-apache
+++ b/devel/tools/rt-apache
@@ -396,10 +396,10 @@ DocumentRoot $RTHOME/share/html
     FastCgiServer $RTHOME/bin/mason_handler.fcgi -processes $PROCESSES -idle-timeout 300
     ScriptAlias $PATH $RTHOME/bin/mason_handler.fcgi/
     <Location $PATH>
-	Order allow,deny
-	Allow from all
-	Options +ExecCGI
-	AddHandler fastcgi-script fcgi
+        Order allow,deny
+        Allow from all
+        Options +ExecCGI
+        AddHandler fastcgi-script fcgi
     </Location>
 </IfDefine>
 
@@ -410,10 +410,10 @@ DocumentRoot $RTHOME/share/html
     FcgidMaxRequestLen 1073741824
     ScriptAlias $PATH $RTHOME/bin/mason_handler.fcgi/
     <Location $PATH>
-	Order allow,deny
-	Allow from all
-	Options +ExecCGI
-	AddHandler fcgid-script fcgi
+        Order allow,deny
+        Allow from all
+        Options +ExecCGI
+        AddHandler fcgid-script fcgi
     </Location>
 </IfDefine>
 </IfDefine>
@@ -427,7 +427,7 @@ DocumentRoot $RTHOME/share/html
     SSLMutex file:$RTHOME/var/ssl_mutex
     <VirtualHost *:$SSL>
         SSLEngine on
-	SSLCertificateFile    $TOOLS/localhost.crt
-	SSLCertificateKeyFile $TOOLS/localhost.key
+        SSLCertificateFile    $TOOLS/localhost.crt
+        SSLCertificateKeyFile $TOOLS/localhost.key
     </VirtualHost>
 </IfDefine>
diff --git a/etc/acl.Pg b/etc/acl.Pg
index 461dbfd..9cd06ec 100755
--- a/etc/acl.Pg
+++ b/etc/acl.Pg
@@ -66,7 +66,7 @@ sub acl {
     # if there's already an rt_user, use it.
     my @row = $dbh->selectrow_array( "SELECT usename FROM pg_user WHERE usename = '$db_user'" );
     unless ( $row[0] ) {
-	 push @acls, "CREATE USER \"$db_user\" WITH PASSWORD '$db_pass' NOCREATEDB NOCREATEUSER;";
+         push @acls, "CREATE USER \"$db_user\" WITH PASSWORD '$db_pass' NOCREATEDB NOCREATEUSER;";
     }
 
     my $sequence_right
diff --git a/etc/initialdata b/etc/initialdata
index 96867e0..72c14b9 100755
--- a/etc/initialdata
+++ b/etc/initialdata
@@ -224,7 +224,7 @@ Greetings,
 
 This message has been automatically generated in response to the
 creation of a trouble ticket regarding:
-	"{$Ticket->Subject()}", 
+        "{$Ticket->Subject()}", 
 a summary of which appears below.
 
 There is no need to reply to this message right now.  Your ticket has been
@@ -474,10 +474,10 @@ Your new password is:
 }
     },
 
-	       {   Queue       => '0',
-		   Name        => 'Email Digest',    # loc
-		   Description => 'Email template for periodic notification digests',  # loc
-		   Content => q[Subject: RT Email Digest
+               {   Queue       => '0',
+                   Name        => 'Email Digest',    # loc
+                   Description => 'Email template for periodic notification digests',  # loc
+                   Content => q[Subject: RT Email Digest
 
 { $Argument }
 ],
diff --git a/etc/schema.Oracle b/etc/schema.Oracle
index 56b02f5..52ce347 100755
--- a/etc/schema.Oracle
+++ b/etc/schema.Oracle
@@ -1,19 +1,19 @@
 
 CREATE SEQUENCE ATTACHMENTS_seq;
 CREATE TABLE Attachments (
-  	id 		NUMBER(11,0) 
-			CONSTRAINT Attachments_Key PRIMARY KEY,
-  	TransactionId	NUMBER(11,0) NOT NULL,
-	Parent 		NUMBER(11,0) DEFAULT 0 NOT NULL, 
-  	MessageId 	VARCHAR2(160),
-  	Subject 	VARCHAR2(255),
-  	Filename 	VARCHAR2(255),
-  	ContentType 	VARCHAR2(80),
-  	ContentEncoding VARCHAR2(80),
-  	Content 	CLOB,
-  	Headers 	CLOB,
-	Creator 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 	DATE
+        id              NUMBER(11,0) 
+                        CONSTRAINT Attachments_Key PRIMARY KEY,
+        TransactionId   NUMBER(11,0) NOT NULL,
+        Parent          NUMBER(11,0) DEFAULT 0 NOT NULL, 
+        MessageId       VARCHAR2(160),
+        Subject         VARCHAR2(255),
+        Filename        VARCHAR2(255),
+        ContentType     VARCHAR2(80),
+        ContentEncoding VARCHAR2(80),
+        Content         CLOB,
+        Headers         CLOB,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE
 );
 CREATE INDEX Attachments2 ON Attachments (TransactionId);
 CREATE INDEX Attachments3 ON Attachments (Parent, TransactionId);
@@ -21,22 +21,22 @@ CREATE INDEX Attachments3 ON Attachments (Parent, TransactionId);
 
 CREATE SEQUENCE QUEUES_seq;
 CREATE TABLE Queues (
-	id 			NUMBER(11,0) 
-		CONSTRAINT Queues_Key PRIMARY KEY,
-	Name 			VARCHAR2(200) CONSTRAINT Queues_Name_Unique UNIQUE NOT NULL,
-	Description 		VARCHAR2(255),
-	CorrespondAddress 	VARCHAR2(120),
-	CommentAddress 		VARCHAR2(120),
-	Lifecycle 		VARCHAR2(32),
-	SubjectTag 		VARCHAR2(120),
-	InitialPriority 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	FinalPriority 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	DefaultDueIn 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created 		DATE,
-	LastUpdatedBy 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated		DATE,
-	Disabled 		NUMBER(11,0) DEFAULT 0 NOT NULL
+        id                      NUMBER(11,0) 
+                CONSTRAINT Queues_Key PRIMARY KEY,
+        Name                    VARCHAR2(200) CONSTRAINT Queues_Name_Unique UNIQUE NOT NULL,
+        Description             VARCHAR2(255),
+        CorrespondAddress       VARCHAR2(120),
+        CommentAddress          VARCHAR2(120),
+        Lifecycle               VARCHAR2(32),
+        SubjectTag              VARCHAR2(120),
+        InitialPriority         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        FinalPriority           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        DefaultDueIn            NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE,
+        LastUpdatedBy           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated             DATE,
+        Disabled                NUMBER(11,0) DEFAULT 0 NOT NULL
 );
  CREATE  INDEX Queues1 ON Queues (LOWER(Name));
 CREATE INDEX Queues2 ON Queues (Disabled);
@@ -44,17 +44,17 @@ CREATE INDEX Queues2 ON Queues (Disabled);
 
 CREATE SEQUENCE LINKS_seq;
 CREATE TABLE Links (
-  	id 		NUMBER(11,0) 
-		CONSTRAINT Links_Key PRIMARY KEY,
-	Base 		VARCHAR2(240),
-	Target 		VARCHAR2(240),
-  	Type 		VARCHAR2(20) NOT NULL,
-	LocalTarget	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LocalBase	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdatedBy 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	LastUpdated 	DATE,
-	Creator 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 	DATE
+        id              NUMBER(11,0) 
+                CONSTRAINT Links_Key PRIMARY KEY,
+        Base            VARCHAR2(240),
+        Target          VARCHAR2(240),
+        Type            VARCHAR2(20) NOT NULL,
+        LocalTarget     NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LocalBase       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE
 );
 CREATE UNIQUE INDEX Links1 ON Links (Base, Target, Type);
 CREATE INDEX Links2 ON Links (Base, Type);
@@ -64,29 +64,29 @@ CREATE INDEX Links4 ON Links(Type,LocalBase);
 
 CREATE SEQUENCE PRINCIPALS_seq;
 CREATE TABLE Principals (
-	id		NUMBER(11,0) 
-		CONSTRAINT Principals_Key PRIMARY KEY,
-	PrincipalType	VARCHAR2(16),
-	ObjectId	NUMBER(11,0),
-	Disabled	NUMBER(11,0) DEFAULT 0 NOT NULL
+        id              NUMBER(11,0) 
+                CONSTRAINT Principals_Key PRIMARY KEY,
+        PrincipalType   VARCHAR2(16),
+        ObjectId        NUMBER(11,0),
+        Disabled        NUMBER(11,0) DEFAULT 0 NOT NULL
 );
 CREATE UNIQUE  INDEX Principals2 ON Principals (ObjectId);
 
 
 CREATE SEQUENCE GROUPS_seq;
 CREATE TABLE Groups (
-	id 		NUMBER(11,0) 
-		CONSTRAINT Groups_Key PRIMARY KEY,
-	Name 		VARCHAR2(200),
-	Description 	VARCHAR2(255),
-	Domain		VARCHAR2(64),
-	Type		VARCHAR2(64),
-	Instance	NUMBER(11,0) DEFAULT 0, -- NOT NULL
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE
---	Instance	VARCHAR2(64)
+        id              NUMBER(11,0) 
+                CONSTRAINT Groups_Key PRIMARY KEY,
+        Name            VARCHAR2(200),
+        Description     VARCHAR2(255),
+        Domain          VARCHAR2(64),
+        Type            VARCHAR2(64),
+        Instance        NUMBER(11,0) DEFAULT 0, -- NOT NULL
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
+--      Instance        VARCHAR2(64)
 );
 CREATE INDEX Groups1 ON Groups (LOWER(Domain), Instance, LOWER(Type), id);
 CREATE INDEX Groups2 ON Groups (LOWER(Type), Instance, LOWER(Domain));
@@ -94,116 +94,116 @@ CREATE INDEX Groups2 ON Groups (LOWER(Type), Instance, LOWER(Domain));
 
 CREATE SEQUENCE SCRIPCONDITIONS_seq;
 CREATE TABLE ScripConditions (
- 	id 			NUMBER(11, 0) 
-		CONSTRAINT ScripConditions_Key PRIMARY KEY,
-	Name 			VARCHAR2(200),
-	Description 		VARCHAR2(255),
-	ExecModule		VARCHAR2(60),
-	Argument		VARCHAR2(255),
-	ApplicableTransTypes	VARCHAR2(60),
-  	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 		DATE,
-  	LastUpdatedBy 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	LastUpdated		DATE
+        id                      NUMBER(11, 0) 
+                CONSTRAINT ScripConditions_Key PRIMARY KEY,
+        Name                    VARCHAR2(200),
+        Description             VARCHAR2(255),
+        ExecModule              VARCHAR2(60),
+        Argument                VARCHAR2(255),
+        ApplicableTransTypes    VARCHAR2(60),
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE,
+        LastUpdatedBy           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated             DATE
 );
 
 
 CREATE SEQUENCE TRANSACTIONS_seq;
 CREATE TABLE Transactions (
-  	id 			NUMBER(11,0) 
-		CONSTRAINT Transactions_Key PRIMARY KEY,
-  	ObjectType 		VARCHAR2(255),
-  	ObjectId		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	TimeTaken 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Type 			VARCHAR2(20),
-  	Field 			VARCHAR2(40),
-  	OldValue 		VARCHAR2(255),
-  	NewValue 		VARCHAR2(255),
-  	ReferenceType 		VARCHAR2(255),
-  	OldReference 		NUMBER(11,0),
-  	NewReference 		NUMBER(11,0),
-  	Data 			VARCHAR2(255),
-  	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 		DATE
+        id                      NUMBER(11,0) 
+                CONSTRAINT Transactions_Key PRIMARY KEY,
+        ObjectType              VARCHAR2(255),
+        ObjectId                NUMBER(11,0) DEFAULT 0 NOT NULL,
+        TimeTaken               NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Type                    VARCHAR2(20),
+        Field                   VARCHAR2(40),
+        OldValue                VARCHAR2(255),
+        NewValue                VARCHAR2(255),
+        ReferenceType           VARCHAR2(255),
+        OldReference            NUMBER(11,0),
+        NewReference            NUMBER(11,0),
+        Data                    VARCHAR2(255),
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE
 );
 CREATE INDEX Transactions1 ON Transactions (ObjectType, ObjectId);
 
 
 CREATE SEQUENCE SCRIPS_seq;
 CREATE TABLE Scrips (
-  	id 		NUMBER(11,0) 
-		CONSTRAINT Scrips_Key PRIMARY KEY,	
-	Description	VARCHAR2(255),
-	ScripCondition 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	ScripAction	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	ConditionRules	CLOB,
-	ActionRules	CLOB,
-	CustomIsApplicableCode	CLOB,
-	CustomPrepareCode	CLOB,
-	CustomCommitCode	CLOB,
-	Disabled 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Template	VARCHAR2(200) NOT NULL,
-  	Creator 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 	DATE,
-  	LastUpdatedBy 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	LastUpdated 	DATE  
+        id              NUMBER(11,0) 
+                CONSTRAINT Scrips_Key PRIMARY KEY,      
+        Description     VARCHAR2(255),
+        ScripCondition  NUMBER(11,0) DEFAULT 0 NOT NULL,
+        ScripAction     NUMBER(11,0) DEFAULT 0 NOT NULL,
+        ConditionRules  CLOB,
+        ActionRules     CLOB,
+        CustomIsApplicableCode  CLOB,
+        CustomPrepareCode       CLOB,
+        CustomCommitCode        CLOB,
+        Disabled        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Template        VARCHAR2(200) NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE  
 );
 
 CREATE SEQUENCE OBJECTSCRIPS_seq;
 CREATE TABLE ObjectScrips (
-	id		NUMBER(11,0)
+        id              NUMBER(11,0)
                  CONSTRAINT ObjectScrips_Key PRIMARY KEY,
         Scrip       NUMBER(11,0)  NOT NULL,
-	Stage		VARCHAR2(32) DEFAULT 'TransactionCreate' NOT NULL,
+        Stage           VARCHAR2(32) DEFAULT 'TransactionCreate' NOT NULL,
         ObjectId              NUMBER(11,0)  NOT NULL,
-	SortOrder	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE
+        SortOrder       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
 );
 CREATE UNIQUE INDEX ObjectScrips1 ON ObjectScrips (ObjectId, Scrip);
 
 CREATE SEQUENCE ACL_seq;
 CREATE TABLE ACL (
-	id 		NUMBER(11,0) 
-		CONSTRAINT ACL_Key PRIMARY KEY,
-	PrincipalType 	VARCHAR2(25) NOT NULL,
-	PrincipalId 	NUMBER(11,0) NOT NULL,
-	RightName	VARCHAR2(25) NOT NULL,
-	ObjectType	VARCHAR2(25) NOT NULL,
-	ObjectId	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created 	DATE,
-	LastUpdatedBy 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated 	DATE
+        id              NUMBER(11,0) 
+                CONSTRAINT ACL_Key PRIMARY KEY,
+        PrincipalType   VARCHAR2(25) NOT NULL,
+        PrincipalId     NUMBER(11,0) NOT NULL,
+        RightName       VARCHAR2(25) NOT NULL,
+        ObjectType      VARCHAR2(25) NOT NULL,
+        ObjectId        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
 );
 CREATE INDEX ACL1 ON ACL(RightName, ObjectType, ObjectId, PrincipalType, PrincipalId);
 
 
 CREATE SEQUENCE GROUPMEMBERS_seq;
 CREATE TABLE GroupMembers (
-	id 		NUMBER(11,0) 
-		CONSTRAINT GroupMembers_Key PRIMARY KEY,
-	GroupId 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	MemberId 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE
+        id              NUMBER(11,0) 
+                CONSTRAINT GroupMembers_Key PRIMARY KEY,
+        GroupId         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        MemberId        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
 );
 CREATE UNIQUE INDEX GroupMembers1 ON GroupMembers (GroupId, MemberId);
 
 
 CREATE SEQUENCE CachedGroupMembers_seq;
 CREATE TABLE CachedGroupMembers (
-	id		NUMBER(11,0) 
-		CONSTRAINT CachedGroupMembers_Key PRIMARY KEY,
-	GroupId		NUMBER(11,0),
-	MemberId	NUMBER(11,0),
-	Via		NUMBER(11,0),
-	ImmediateParentId	NUMBER(11,0),
-	Disabled	NUMBER(11,0) DEFAULT 0 NOT NULL
+        id              NUMBER(11,0) 
+                CONSTRAINT CachedGroupMembers_Key PRIMARY KEY,
+        GroupId         NUMBER(11,0),
+        MemberId        NUMBER(11,0),
+        Via             NUMBER(11,0),
+        ImmediateParentId       NUMBER(11,0),
+        Disabled        NUMBER(11,0) DEFAULT 0 NOT NULL
 );
 CREATE INDEX DisGrouMem ON CachedGroupMembers (GroupId, MemberId, Disabled);
 CREATE INDEX GrouMem ON CachedGroupMembers (GroupId, MemberId);
@@ -212,43 +212,43 @@ CREATE INDEX CachedGroupMembers3 on CachedGroupMembers (MemberId, ImmediateParen
 
 CREATE SEQUENCE USERS_seq;
 CREATE TABLE Users (
-  	id 			NUMBER(11,0) 
-		CONSTRAINT Users_Key PRIMARY KEY,
-  	Name 			VARCHAR2(200) CONSTRAINT Users_Name_Unique 
-		unique  NOT NULL,
-  	Password 		VARCHAR2(256),
-  	AuthToken 		VARCHAR2(16),
-  	Comments 		CLOB,
-  	Signature 		CLOB,
-  	EmailAddress 		VARCHAR2(120),
-  	FreeFormContactInfo 	CLOB,
-	Organization		VARCHAR2(200),
-  	RealName 		VARCHAR2(120),
-  	NickName 		VARCHAR2(16),
-  	Lang 			VARCHAR2(16),
-	EmailEncoding		VARCHAR2(16),
-	WebEncoding		VARCHAR2(16),
-	ExternalContactInfoId	VARCHAR2(100),
-	ContactInfoSystem	VARCHAR2(30),
-	ExternalAuthId 		VARCHAR2(100),
-	AuthSystem		VARCHAR2(30),
-	Gecos			VARCHAR2(16),
-  	HomePhone 		VARCHAR2(30),
-  	WorkPhone 		VARCHAR2(30),
-  	MobilePhone 		VARCHAR2(30),
-  	PagerPhone 		VARCHAR2(30),
-  	Address1	 	VARCHAR2(200),
-  	Address2 		VARCHAR2(200),
-  	City 			VARCHAR2(100),
-  	State 			VARCHAR2(100),
-  	Zip 			VARCHAR2(16),
-  	Country 		VARCHAR2(50),
-	Timezone		VARCHAR2(50),
-	PGPKey			CLOB,
-  	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 		DATE,
-  	LastUpdatedBy 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	LastUpdated 		DATE
+        id                      NUMBER(11,0) 
+                CONSTRAINT Users_Key PRIMARY KEY,
+        Name                    VARCHAR2(200) CONSTRAINT Users_Name_Unique 
+                unique  NOT NULL,
+        Password                VARCHAR2(256),
+        AuthToken               VARCHAR2(16),
+        Comments                CLOB,
+        Signature               CLOB,
+        EmailAddress            VARCHAR2(120),
+        FreeFormContactInfo     CLOB,
+        Organization            VARCHAR2(200),
+        RealName                VARCHAR2(120),
+        NickName                VARCHAR2(16),
+        Lang                    VARCHAR2(16),
+        EmailEncoding           VARCHAR2(16),
+        WebEncoding             VARCHAR2(16),
+        ExternalContactInfoId   VARCHAR2(100),
+        ContactInfoSystem       VARCHAR2(30),
+        ExternalAuthId          VARCHAR2(100),
+        AuthSystem              VARCHAR2(30),
+        Gecos                   VARCHAR2(16),
+        HomePhone               VARCHAR2(30),
+        WorkPhone               VARCHAR2(30),
+        MobilePhone             VARCHAR2(30),
+        PagerPhone              VARCHAR2(30),
+        Address1                VARCHAR2(200),
+        Address2                VARCHAR2(200),
+        City                    VARCHAR2(100),
+        State                   VARCHAR2(100),
+        Zip                     VARCHAR2(16),
+        Country                 VARCHAR2(50),
+        Timezone                VARCHAR2(50),
+        PGPKey                  CLOB,
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE,
+        LastUpdatedBy           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated             DATE
 );
 -- CREATE UNIQUE INDEX Users1 ON Users (Name);
 
@@ -260,30 +260,30 @@ CREATE SEQUENCE TICKETS_seq;
 CREATE TABLE Tickets (
        id                      NUMBER(11, 0) 
                CONSTRAINT Tickets_Key PRIMARY KEY,
-  	EffectiveId		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Queue 			NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Type 			VARCHAR2(16), 		
-  	IssueStatement 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Resolution 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Owner 			NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Subject			VARCHAR2(200) DEFAULT '[no subject]', 
-  	InitialPriority 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	FinalPriority 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Priority 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	TimeEstimated		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	TimeWorked 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Status 			VARCHAR2(64), 		
-	TimeLeft 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Told 			DATE,
-	Starts			DATE,
-	Started			DATE,
-  	Due 			DATE,
-	Resolved		DATE,
-  	LastUpdatedBy 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	LastUpdated 		DATE,
-	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 		DATE,
-  	Disabled 		NUMBER(11,0) DEFAULT 0 NOT NULL
+        EffectiveId             NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Queue                   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Type                    VARCHAR2(16),           
+        IssueStatement          NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Resolution              NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Owner                   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Subject                 VARCHAR2(200) DEFAULT '[no subject]', 
+        InitialPriority         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        FinalPriority           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Priority                NUMBER(11,0) DEFAULT 0 NOT NULL,
+        TimeEstimated           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        TimeWorked              NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Status                  VARCHAR2(64),           
+        TimeLeft                NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Told                    DATE,
+        Starts                  DATE,
+        Started                 DATE,
+        Due                     DATE,
+        Resolved                DATE,
+        LastUpdatedBy           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated             DATE,
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE,
+        Disabled                NUMBER(11,0) DEFAULT 0 NOT NULL
 );
 CREATE INDEX Tickets1 ON Tickets (Queue, Status);
 CREATE INDEX Tickets2 ON Tickets (Owner);
@@ -294,68 +294,68 @@ CREATE INDEX Tickets6 ON Tickets (EffectiveId, Type);
 
 CREATE SEQUENCE SCRIPACTIONS_seq;
 CREATE TABLE ScripActions (
-  id		NUMBER(11,0) 
-		CONSTRAINT ScripActions_Key PRIMARY KEY,
-  Name		VARCHAR2(200),
-  Description	VARCHAR2(255),
-  ExecModule	VARCHAR2(60),
-  Argument	VARCHAR2(255),
-  Creator	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  Created	DATE,
-  LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  LastUpdated	DATE
+  id            NUMBER(11,0) 
+                CONSTRAINT ScripActions_Key PRIMARY KEY,
+  Name          VARCHAR2(200),
+  Description   VARCHAR2(255),
+  ExecModule    VARCHAR2(60),
+  Argument      VARCHAR2(255),
+  Creator       NUMBER(11,0) DEFAULT 0 NOT NULL,
+  Created       DATE,
+  LastUpdatedBy NUMBER(11,0) DEFAULT 0 NOT NULL,
+  LastUpdated   DATE
 );
 
 
 CREATE SEQUENCE TEMPLATES_seq;
 CREATE TABLE Templates (
-  	id 		NUMBER(11,0) 
-		CONSTRAINT Templates_Key PRIMARY KEY,
-	Queue 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Name		VARCHAR2(200) NOT NULL,
-	Description	VARCHAR2(255),
-	Type		VARCHAR2(16),
-  	Language 	VARCHAR2(16), 
-  	TranslationOf 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Content 	CLOB,
-  	LastUpdated 	DATE,
-  	LastUpdatedBy 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Creator 	NUMBER(11,0) DEFAULT 0 NOT NULL,
-  	Created 	DATE
+        id              NUMBER(11,0) 
+                CONSTRAINT Templates_Key PRIMARY KEY,
+        Queue           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Name            VARCHAR2(200) NOT NULL,
+        Description     VARCHAR2(255),
+        Type            VARCHAR2(16),
+        Language        VARCHAR2(16), 
+        TranslationOf   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Content         CLOB,
+        LastUpdated     DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE
 );
 
 
 CREATE SEQUENCE OBJECTCUSTOMFIELDS_seq;
 CREATE TABLE ObjectCustomFields (
-	id		NUMBER(11,0)
+        id              NUMBER(11,0)
                  CONSTRAINT ObjectCustomFields_Key PRIMARY KEY,
         CustomField       NUMBER(11,0)  NOT NULL,
         ObjectId              NUMBER(11,0)  NOT NULL,
-	SortOrder	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE
+        SortOrder       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
 );
 
 
 CREATE SEQUENCE OBJECTCUSTOMFIELDVALUES_seq;
 CREATE TABLE ObjectCustomFieldValues (
-	id		NUMBER(11,0) 
-		CONSTRAINT ObjectCustomFieldValues_Key PRIMARY KEY,
-	CustomField	NUMBER(11,0) NOT NULL,
-	ObjectType	VARCHAR2(25) NOT NULL,
-	ObjectId	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	SortOrder	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Content		VARCHAR2(255),
-  	LargeContent 	CLOB,
-  	ContentType 	VARCHAR2(80),
-  	ContentEncoding VARCHAR2(80),
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE,
-	Disabled	NUMBER(11,0) DEFAULT 0 NOT NULL
+        id              NUMBER(11,0) 
+                CONSTRAINT ObjectCustomFieldValues_Key PRIMARY KEY,
+        CustomField     NUMBER(11,0) NOT NULL,
+        ObjectType      VARCHAR2(25) NOT NULL,
+        ObjectId        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        SortOrder       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Content         VARCHAR2(255),
+        LargeContent    CLOB,
+        ContentType     VARCHAR2(80),
+        ContentEncoding VARCHAR2(80),
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE,
+        Disabled        NUMBER(11,0) DEFAULT 0 NOT NULL
 );
 
 CREATE INDEX ObjectCustomFieldValues1 ON ObjectCustomFieldValues (Content); 
@@ -363,57 +363,57 @@ CREATE INDEX ObjectCustomFieldValues2 ON ObjectCustomFieldValues (CustomField,Ob
 
 CREATE SEQUENCE CUSTOMFIELDS_seq;
 CREATE TABLE CustomFields (
-	id		NUMBER(11,0) 
-		CONSTRAINT CustomFields_Key PRIMARY KEY,
-	Name		VARCHAR2(200),
-	Type		VARCHAR2(200),
-	RenderType	VARCHAR2(64),
-	MaxValues	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Pattern		CLOB,
+        id              NUMBER(11,0) 
+                CONSTRAINT CustomFields_Key PRIMARY KEY,
+        Name            VARCHAR2(200),
+        Type            VARCHAR2(200),
+        RenderType      VARCHAR2(64),
+        MaxValues       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Pattern         CLOB,
         Repeated        NUMBER(11,0) DEFAULT 0 NOT NULL,
-	ValuesClass	VARCHAR2(64),
+        ValuesClass     VARCHAR2(64),
         BasedOn         NUMBER(11,0) NULL,
-	Description	VARCHAR2(255),
-	SortOrder	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LookupType	VARCHAR2(255),
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE,
-	Disabled	NUMBER(11,0) DEFAULT 0 NOT NULL
+        Description     VARCHAR2(255),
+        SortOrder       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LookupType      VARCHAR2(255),
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE,
+        Disabled        NUMBER(11,0) DEFAULT 0 NOT NULL
 );
 
 
 CREATE SEQUENCE CUSTOMFIELDVALUES_seq;
 CREATE TABLE CustomFieldValues (
-	id		NUMBER(11,0) 
-		CONSTRAINT CustomFieldValues_Key PRIMARY KEY,
-	CustomField	NUMBER(11,0),
-	Name		VARCHAR2(200),
-	Description	VARCHAR2(255),
-	SortOrder	NUMBER(11,0) DEFAULT 0 NOT NULL,
+        id              NUMBER(11,0) 
+                CONSTRAINT CustomFieldValues_Key PRIMARY KEY,
+        CustomField     NUMBER(11,0),
+        Name            VARCHAR2(200),
+        Description     VARCHAR2(255),
+        SortOrder       NUMBER(11,0) DEFAULT 0 NOT NULL,
     Category    VARCHAR2(255),
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
 );
 
 CREATE INDEX CustomFieldValues1 ON CustomFieldValues (CustomField);
 
 CREATE SEQUENCE ATTRIBUTES_seq;
 CREATE TABLE Attributes (
-	id 			NUMBER(11,0) PRIMARY KEY,
-	Name 			VARCHAR2(255) NOT NULL,
-	Description 		VARCHAR2(255),
-  	Content 	CLOB,
+        id                      NUMBER(11,0) PRIMARY KEY,
+        Name                    VARCHAR2(255) NOT NULL,
+        Description             VARCHAR2(255),
+        Content         CLOB,
     ContentType VARCHAR(16),
-	ObjectType	VARCHAR2(25) NOT NULL,
-	ObjectId	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created 		DATE,
-	LastUpdatedBy 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated		DATE
+        ObjectType      VARCHAR2(25) NOT NULL,
+        ObjectId        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE,
+        LastUpdatedBy           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated             DATE
 );
 
 CREATE INDEX Attributes1 on Attributes(Name);
@@ -421,10 +421,10 @@ CREATE INDEX Attributes2 on Attributes(ObjectType, ObjectId);
 
 
 CREATE TABLE sessions (
-	id		VARCHAR2(32) 
-		CONSTRAINT Sessions_Key PRIMARY KEY,
-	a_session	CLOB,
-	LastUpdated	DATE
+        id              VARCHAR2(32) 
+                CONSTRAINT Sessions_Key PRIMARY KEY,
+        a_session       CLOB,
+        LastUpdated     DATE
 );
 
 CREATE SEQUENCE Classes_seq;
diff --git a/etc/schema.SQLite b/etc/schema.SQLite
index 28b97f2..4d0f12e 100755
--- a/etc/schema.SQLite
+++ b/etc/schema.SQLite
@@ -364,14 +364,14 @@ CREATE TABLE Templates (
 CREATE TABLE ObjectCustomFieldValues (
   id INTEGER NOT NULL  ,
   CustomField int NOT NULL  ,
-  ObjectType varchar(255) NOT NULL,	    # Final target of the Object
-  ObjectId int NOT NULL  ,		    # New -- Replaces Ticket
+  ObjectType varchar(255) NOT NULL,         # Final target of the Object
+  ObjectId int NOT NULL  ,                  # New -- Replaces Ticket
   SortOrder integer NOT NULL DEFAULT 0  ,
 
   Content varchar(255) NULL  ,
-  LargeContent LONGTEXT NULL,		    # New -- to hold 255+ strings
-  ContentType varchar(80) NULL,		    # New -- only text/* gets searched
-  ContentEncoding varchar(80) NULL  ,	    # New -- for binary Content
+  LargeContent LONGTEXT NULL,               # New -- to hold 255+ strings
+  ContentType varchar(80) NULL,             # New -- only text/* gets searched
+  ContentEncoding varchar(80) NULL  ,       # New -- for binary Content
 
   Creator integer NOT NULL DEFAULT 0  ,
   Created DATETIME NULL  ,
@@ -389,10 +389,10 @@ CREATE INDEX ObjectCustomFieldValues2 ON ObjectCustomFieldValues (CustomField,Ob
 CREATE TABLE CustomFields (
   id INTEGER NOT NULL  ,
   Name varchar(200) NULL  ,
-  Type varchar(200) NULL  ,	# Changed -- 'Single' and 'Multiple' is moved out
+  Type varchar(200) NULL  ,     # Changed -- 'Single' and 'Multiple' is moved out
   RenderType varchar(64) NULL  ,
-  MaxValues integer,		# New -- was 'Single'(1) and 'Multiple'(0)
-  Pattern varchar(65536) NULL  ,	# New -- Must validate against this
+  MaxValues integer,            # New -- was 'Single'(1) and 'Multiple'(0)
+  Pattern varchar(65536) NULL  ,        # New -- Must validate against this
   Repeated int2 NOT NULL DEFAULT 0 , # New -- repeated table entry
   BasedOn INTEGER NULL,
   ValuesClass varchar(64) NULL  ,
diff --git a/etc/schema.mysql b/etc/schema.mysql
index 96373a5..ab81be4 100755
--- a/etc/schema.mysql
+++ b/etc/schema.mysql
@@ -342,14 +342,14 @@ CREATE TABLE Templates (
 CREATE TABLE ObjectCustomFieldValues (
   id INTEGER NOT NULL  AUTO_INCREMENT,
   CustomField int NOT NULL  ,
-  ObjectType varchar(255) CHARACTER SET ascii NOT NULL,	    # Final target of the Object
-  ObjectId int NOT NULL  ,		    # New -- Replaces Ticket
+  ObjectType varchar(255) CHARACTER SET ascii NOT NULL,     # Final target of the Object
+  ObjectId int NOT NULL  ,                  # New -- Replaces Ticket
   SortOrder integer NOT NULL DEFAULT 0  ,   # New -- ordering for multiple values
 
   Content varchar(255) NULL  ,
-  LargeContent LONGBLOB NULL,		    # New -- to hold 255+ strings
-  ContentType varchar(80) CHARACTER SET ascii NULL,		    # New -- only text/* gets searched
-  ContentEncoding varchar(80) CHARACTER SET ascii NULL  ,	    # New -- for binary Content
+  LargeContent LONGBLOB NULL,               # New -- to hold 255+ strings
+  ContentType varchar(80) CHARACTER SET ascii NULL,                 # New -- only text/* gets searched
+  ContentEncoding varchar(80) CHARACTER SET ascii NULL  ,           # New -- for binary Content
 
   Creator integer NOT NULL DEFAULT 0  ,
   Created DATETIME NULL  ,
@@ -367,10 +367,10 @@ CREATE INDEX ObjectCustomFieldValues2 ON ObjectCustomFieldValues (CustomField,Ob
 CREATE TABLE CustomFields (
   id INTEGER NOT NULL  AUTO_INCREMENT,
   Name varchar(200) NULL  ,
-  Type varchar(200) CHARACTER SET ascii NULL  ,	# Changed -- 'Single' and 'Multiple' is moved out
+  Type varchar(200) CHARACTER SET ascii NULL  , # Changed -- 'Single' and 'Multiple' is moved out
   RenderType varchar(64) CHARACTER SET ascii NULL  ,
-  MaxValues integer,		# New -- was 'Single'(1) and 'Multiple'(0)
-  Pattern TEXT NULL  ,	# New -- Must validate against this
+  MaxValues integer,            # New -- was 'Single'(1) and 'Multiple'(0)
+  Pattern TEXT NULL  ,  # New -- Must validate against this
   Repeated int2 NOT NULL DEFAULT 0 , # New -- repeated table entry
   BasedOn INTEGER NULL,
   ValuesClass varchar(64) CHARACTER SET ascii NULL  ,
diff --git a/etc/upgrade/3.1.0/schema.Oracle b/etc/upgrade/3.1.0/schema.Oracle
index a8aae18..8a3c142 100644
--- a/etc/upgrade/3.1.0/schema.Oracle
+++ b/etc/upgrade/3.1.0/schema.Oracle
@@ -1,16 +1,16 @@
 CREATE SEQUENCE ATTRIBUTES_seq;
 CREATE TABLE Attributes (
-	id 			NUMBER(11,0) PRIMARY KEY,
-	Name 			VARCHAR2(255) NOT NULL,
-	Description 		VARCHAR2(255),
-  	Content 	CLOB,
+        id                      NUMBER(11,0) PRIMARY KEY,
+        Name                    VARCHAR2(255) NOT NULL,
+        Description             VARCHAR2(255),
+        Content         CLOB,
     ContentType VARCHAR(16),
-	ObjectType	VARCHAR2(25) NOT NULL,
-	ObjectId	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created 		DATE,
-	LastUpdatedBy 		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated		DATE
+        ObjectType      VARCHAR2(25) NOT NULL,
+        ObjectId        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator                 NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created                 DATE,
+        LastUpdatedBy           NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated             DATE
 );
 
 CREATE INDEX Attributes1 on Attributes(Name);
diff --git a/etc/upgrade/3.5.1/content b/etc/upgrade/3.5.1/content
index a125074..59f9dfd 100644
--- a/etc/upgrade/3.5.1/content
+++ b/etc/upgrade/3.5.1/content
@@ -22,16 +22,16 @@ our @Attributes = (
       Description => 'HomepageSettings',
       Content =>
       { 'body' =>
-	[ { type => 'system', name => 'My Tickets' },
-	  { type => 'system', name => 'Unowned Tickets' },
-	  { type => 'component',  name => 'QuickCreate'},
-	],
+        [ { type => 'system', name => 'My Tickets' },
+          { type => 'system', name => 'Unowned Tickets' },
+          { type => 'component',  name => 'QuickCreate'},
+        ],
         'summary' =>
-	[ 
-	  { type => 'component', name => 'MyReminders' },
+        [
+          { type => 'component', name => 'MyReminders' },
           { type => 'component', name => 'Quicksearch' },
-	  { type => 'component', name => 'RefreshHomepage' },
-	]
+          { type => 'component', name => 'RefreshHomepage' },
+        ]
     },
 }
 );
diff --git a/etc/upgrade/3.7.85/content b/etc/upgrade/3.7.85/content
index 8f9a824..e9ec15c 100644
--- a/etc/upgrade/3.7.85/content
+++ b/etc/upgrade/3.7.85/content
@@ -1,12 +1,12 @@
 use strict;
 use warnings;
 
-our @Templates = ( 
-	       
-	       {   Queue       => '0',
-		   Name        => 'Email Digest',    # loc
-		   Description => 'Email template for periodic notification digests',  # loc
-		   Content => q[Subject: RT Email Digest
+our @Templates = (
+
+               {   Queue       => '0',
+                   Name        => 'Email Digest',    # loc
+                   Description => 'Email template for periodic notification digests',  # loc
+                   Content => q[Subject: RT Email Digest
 
 { $Argument }
 ],
diff --git a/etc/upgrade/3.9.5/backcompat b/etc/upgrade/3.9.5/backcompat
index 611ab51..f7b66c9 100644
--- a/etc/upgrade/3.9.5/backcompat
+++ b/etc/upgrade/3.9.5/backcompat
@@ -1 +1 @@
-RT::ACE		LastUpdated LastUpdatedBy Creator Created
+RT::ACE         LastUpdated LastUpdatedBy Creator Created
diff --git a/etc/upgrade/4.1.1/schema.Oracle b/etc/upgrade/4.1.1/schema.Oracle
index 576c0f1..b4aac9d 100644
--- a/etc/upgrade/4.1.1/schema.Oracle
+++ b/etc/upgrade/4.1.1/schema.Oracle
@@ -1,16 +1,16 @@
 CREATE SEQUENCE OBJECTSCRIPS_seq;
 CREATE TABLE ObjectScrips (
-	id		NUMBER(11,0)
+        id              NUMBER(11,0)
                  CONSTRAINT ObjectScrips_Key PRIMARY KEY,
         Scrip       NUMBER(11,0)  NOT NULL,
-	Stage		VARCHAR2(32) DEFAULT 'TransactionCreate' NOT NULL,
+        Stage           VARCHAR2(32) DEFAULT 'TransactionCreate' NOT NULL,
         ObjectId              NUMBER(11,0)  NOT NULL,
-	SortOrder	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Disabled	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Creator		NUMBER(11,0) DEFAULT 0 NOT NULL,
-	Created		DATE,
-	LastUpdatedBy	NUMBER(11,0) DEFAULT 0 NOT NULL,
-	LastUpdated	DATE
+        SortOrder       NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Disabled        NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Creator         NUMBER(11,0) DEFAULT 0 NOT NULL,
+        Created         DATE,
+        LastUpdatedBy   NUMBER(11,0) DEFAULT 0 NOT NULL,
+        LastUpdated     DATE
 );
 ALTER TABLE Scrips ADD COLUMN Disabled int2 NOT NULL DEFAULT 0;
 
diff --git a/lib/RT.pm b/lib/RT.pm
index 467adf9..8722ed6 100644
--- a/lib/RT.pm
+++ b/lib/RT.pm
@@ -478,7 +478,7 @@ sub InitClasses {
                                    "You should delete or repair this Scrip in the admin UI.\n$@\n");
         }
 
-	foreach my $class ( grep $_, RT->Config->Get('CustomFieldValuesSources') ) {
+        foreach my $class ( grep $_, RT->Config->Get('CustomFieldValuesSources') ) {
             local $@;
             eval "require $class; 1" or $RT::Logger->error(
                 "Class '$class' is listed in CustomFieldValuesSources option"
diff --git a/lib/RT/ACE.pm b/lib/RT/ACE.pm
index 5cbe7de..e0a3639 100644
--- a/lib/RT/ACE.pm
+++ b/lib/RT/ACE.pm
@@ -95,16 +95,16 @@ Load an ACE by specifying a paramhash with the following fields:
 
               PrincipalId => undef,
               PrincipalType => undef,
-	      RightName => undef,
+              RightName => undef,
 
         And either:
 
-	      Object => undef,
+              Object => undef,
 
             OR
 
-	      ObjectType => undef,
-	      ObjectId => undef
+              ObjectType => undef,
+              ObjectId => undef
 
 =cut
 
@@ -139,7 +139,7 @@ sub LoadByValues {
 
     my ($object, $object_type, $object_id) = $self->_ParseObjectArg( %args );
     unless( $object ) {
-	return ( 0, $self->loc("System error. Right not granted.") );
+        return ( 0, $self->loc("System error. Right not granted.") );
     }
 
     $self->LoadByCols( PrincipalId   => $princ_obj->Id,
@@ -207,7 +207,7 @@ sub Create {
     }
     ($args{'Object'}, $args{'ObjectType'}, $args{'ObjectId'}) = $self->_ParseObjectArg( %args );
     unless( $args{'Object'} ) {
-	return ( 0, $self->loc("System error. Right not granted.") );
+        return ( 0, $self->loc("System error. Right not granted.") );
     }
 
     # Validate the principal
@@ -331,9 +331,9 @@ sub _Delete {
     my ( $val, $msg ) = $self->SUPER::Delete(@_);
 
     if ($val) {
-	#Clear the key cache. TODO someday we may want to just clear a little bit of the keycache space. 
-	# TODO what about the groups key cache?
-	RT::Principal->InvalidateACLCache();
+        #Clear the key cache. TODO someday we may want to just clear a little bit of the keycache space. 
+        # TODO what about the groups key cache?
+        RT::Principal->InvalidateACLCache();
         $RT::Handle->Commit() unless $InsideTransaction;
         return ( $val, $self->loc('Right revoked') );
     }
@@ -547,21 +547,21 @@ sub _ParseObjectArg {
                  @_ );
 
     if( $args{'Object'} && ($args{'ObjectId'} || $args{'ObjectType'}) ) {
-	$RT::Logger->crit( "Method called with an ObjectType or an ObjectId and Object args" );
-	return ();
+        $RT::Logger->crit( "Method called with an ObjectType or an ObjectId and Object args" );
+        return ();
     } elsif( $args{'Object'} && ref($args{'Object'}) &&  !$args{'Object'}->can('id') ) {
-	$RT::Logger->crit( "Method called called Object that has no id method" );
-	return ();
+        $RT::Logger->crit( "Method called called Object that has no id method" );
+        return ();
     } elsif( $args{'Object'} ) {
-	my $obj = $args{'Object'};
-	return ($obj, ref $obj, $obj->id);
+        my $obj = $args{'Object'};
+        return ($obj, ref $obj, $obj->id);
     } elsif ( $args{'ObjectType'} ) {
-	my $obj =  $args{'ObjectType'}->new( $self->CurrentUser );
-	$obj->Load( $args{'ObjectId'} );
-	return ($obj, ref $obj, $obj->id);
+        my $obj =  $args{'ObjectType'}->new( $self->CurrentUser );
+        $obj->Load( $args{'ObjectId'} );
+        return ($obj, ref $obj, $obj->id);
     } else {
-	$RT::Logger->crit( "Method called with wrong args" );
-	return ();
+        $RT::Logger->crit( "Method called with wrong args" );
+        return ();
     }
 }
 
@@ -706,25 +706,25 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         PrincipalType =>
-		{read => 1, write => 1, sql_type => 12, length => 25,  is_blob => 0,  is_numeric => 0,  type => 'varchar(25)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 25,  is_blob => 0,  is_numeric => 0,  type => 'varchar(25)', default => ''},
         PrincipalId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         RightName =>
-		{read => 1, write => 1, sql_type => 12, length => 25,  is_blob => 0,  is_numeric => 0,  type => 'varchar(25)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 25,  is_blob => 0,  is_numeric => 0,  type => 'varchar(25)', default => ''},
         ObjectType =>
-		{read => 1, write => 1, sql_type => 12, length => 25,  is_blob => 0,  is_numeric => 0,  type => 'varchar(25)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 25,  is_blob => 0,  is_numeric => 0,  type => 'varchar(25)', default => ''},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Action/Autoreply.pm b/lib/RT/Action/Autoreply.pm
index 9286217..ad447fe 100644
--- a/lib/RT/Action/Autoreply.pm
+++ b/lib/RT/Action/Autoreply.pm
@@ -93,18 +93,18 @@ Set this message's return address to the apropriate queue address
 
 sub SetReturnAddress {
     my $self = shift;
-    
+
     my $friendly_name;
 
-	if (RT->Config->Get('UseFriendlyFromLine')) {
-	    $friendly_name = $self->TicketObj->QueueObj->Description ||
-		    $self->TicketObj->QueueObj->Name;
-	}
+    if (RT->Config->Get('UseFriendlyFromLine')) {
+        $friendly_name = $self->TicketObj->QueueObj->Description ||
+            $self->TicketObj->QueueObj->Name;
+    }
 
     $self->SUPER::SetReturnAddress( @_, friendly_name => $friendly_name );
-    
+
 }
-  
+
 
 
 =head2 SetRTSpecialHeaders
diff --git a/lib/RT/Action/CreateTickets.pm b/lib/RT/Action/CreateTickets.pm
index 2f437a7..aa3e7e7 100644
--- a/lib/RT/Action/CreateTickets.pm
+++ b/lib/RT/Action/CreateTickets.pm
@@ -136,11 +136,11 @@ A convoluted example:
 
     my $adminccs = RT::Users->new(RT->SystemUser);
     $adminccs->WhoHaveRight(
-	Right => "AdminGroup",
-	Object =>$groups->First,
-	IncludeSystemRights => undef,
-	IncludeSuperusers => 0,
-	IncludeSubgroupMembers => 0,
+        Right => "AdminGroup",
+        Object =>$groups->First,
+        IncludeSystemRights => undef,
+        IncludeSuperusers => 0,
+        IncludeSubgroupMembers => 0,
     );
 
      our @admins;
diff --git a/lib/RT/Action/EscalatePriority.pm b/lib/RT/Action/EscalatePriority.pm
index 0f74095..66a4451 100644
--- a/lib/RT/Action/EscalatePriority.pm
+++ b/lib/RT/Action/EscalatePriority.pm
@@ -88,62 +88,62 @@ sub Describe  {
   my $self = shift;
   return (ref $self . " will move a ticket's priority toward its final priority.");
 }
-	
+
 
 sub Prepare  {
     my $self = shift;
-    
+
     if ($self->TicketObj->Priority() == $self->TicketObj->FinalPriority()) {
-	# no update necessary.
-	return 0;
+        # no update necessary.
+        return 0;
     }
-   
+
     #compute the number of days until the ticket is due
     my $due = $self->TicketObj->DueObj();
-    
+
 
     # If we don't have a due date, adjust the priority by one
     # until we hit the final priority
     if ($due->Unix() < 1) {
-	if ( $self->TicketObj->Priority > $self->TicketObj->FinalPriority ){
-	    $self->{'prio'} = ($self->TicketObj->Priority - 1);
-	    return 1;
-	}
-	elsif ( $self->TicketObj->Priority < $self->TicketObj->FinalPriority ){
-	    $self->{'prio'} = ($self->TicketObj->Priority + 1);
-	    return 1;
-	}
-	# otherwise the priority is at the final priority. we don't need to
-	# Continue
-	else {
-	    return 0;
-	}
+        if ( $self->TicketObj->Priority > $self->TicketObj->FinalPriority ){
+            $self->{'prio'} = ($self->TicketObj->Priority - 1);
+            return 1;
+        }
+        elsif ( $self->TicketObj->Priority < $self->TicketObj->FinalPriority ){
+            $self->{'prio'} = ($self->TicketObj->Priority + 1);
+            return 1;
+        }
+        # otherwise the priority is at the final priority. we don't need to
+        # Continue
+        else {
+            return 0;
+        }
     }
 
     # we've got a due date. now there are other things we should do
-    else { 
-	my $diff_in_seconds = $due->Diff(time());    
-	my $diff_in_days = int( $diff_in_seconds / 86400);    
-	
-	#if we haven't hit the due date yet
-	if ($diff_in_days > 0 ) {	
-	    
-	    # compute the difference between the current priority and the
-	    # final priority
-	    
-	    my $prio_delta = 
-	      $self->TicketObj->FinalPriority() - $self->TicketObj->Priority;
-	    
-	    my $inc_priority_by = int( $prio_delta / $diff_in_days );
-	    
-	    #set the ticket's priority to that amount
-	    $self->{'prio'} = $self->TicketObj->Priority + $inc_priority_by;
-	    
-	}
-	#if $days is less than 1, set priority to final_priority
-	else {	
-	    $self->{'prio'} = $self->TicketObj->FinalPriority();
-	}
+    else {
+        my $diff_in_seconds = $due->Diff(time());
+        my $diff_in_days = int( $diff_in_seconds / 86400);
+
+        #if we haven't hit the due date yet
+        if ($diff_in_days > 0 ) {
+
+            # compute the difference between the current priority and the
+            # final priority
+
+            my $prio_delta =
+              $self->TicketObj->FinalPriority() - $self->TicketObj->Priority;
+
+            my $inc_priority_by = int( $prio_delta / $diff_in_days );
+
+            #set the ticket's priority to that amount
+            $self->{'prio'} = $self->TicketObj->Priority + $inc_priority_by;
+
+        }
+        #if $days is less than 1, set priority to final_priority
+        else {
+            $self->{'prio'} = $self->TicketObj->FinalPriority();
+        }
 
     }
     return 1;
@@ -154,7 +154,7 @@ sub Commit {
    my ($val, $msg) = $self->TicketObj->SetPriority($self->{'prio'});
 
    unless ($val) {
-	$RT::Logger->debug($self . " $msg"); 
+        $RT::Logger->debug($self . " $msg");
    }
 }
 
diff --git a/lib/RT/Action/LinearEscalate.pm b/lib/RT/Action/LinearEscalate.pm
index 0a0825e..d02a832 100644
--- a/lib/RT/Action/LinearEscalate.pm
+++ b/lib/RT/Action/LinearEscalate.pm
@@ -198,7 +198,7 @@ sub Prepare {
     my $percent_complete = ($now-$starts)/($due - $starts);
 
     my $new_priority = int($percent_complete * $priority_range) + ($ticket->InitialPriority || 0);
-	$new_priority = $ticket->FinalPriority if $new_priority > $ticket->FinalPriority;
+    $new_priority = $ticket->FinalPriority if $new_priority > $ticket->FinalPriority;
     $self->{'new_priority'} = $new_priority;
 
     return 1;
diff --git a/lib/RT/Action/NotifyGroupAsComment.pm b/lib/RT/Action/NotifyGroupAsComment.pm
index aee1ee5..09e307e 100644
--- a/lib/RT/Action/NotifyGroupAsComment.pm
+++ b/lib/RT/Action/NotifyGroupAsComment.pm
@@ -65,9 +65,9 @@ use warnings;
 use base qw(RT::Action::NotifyGroup);
 
 sub SetReturnAddress {
-	my $self = shift;
-	$self->{'comment'} = 1;
-	return $self->SUPER::SetReturnAddress( @_, is_comment => 1 );
+    my $self = shift;
+    $self->{'comment'} = 1;
+    return $self->SUPER::SetReturnAddress( @_, is_comment => 1 );
 }
 
 =head1 AUTHOR
diff --git a/lib/RT/Action/RecordComment.pm b/lib/RT/Action/RecordComment.pm
index e6397e8..757ef25 100644
--- a/lib/RT/Action/RecordComment.pm
+++ b/lib/RT/Action/RecordComment.pm
@@ -59,11 +59,12 @@ been started, to make a comment on the ticket.
 
 =head1 SYNOPSIS
 
-my $action_obj = RT::Action::RecordComment->new('TicketObj'   => $ticket_obj,
-						'TemplateObj' => $template_obj,
-						);
-my $result = $action_obj->Prepare();
-$action_obj->Commit() if $result;
+    my $action_obj = RT::Action::RecordComment->new(
+        'TicketObj'   => $ticket_obj,
+        'TemplateObj' => $template_obj,
+    );
+    my $result = $action_obj->Prepare();
+    $action_obj->Commit() if $result;
 
 =head1 METHODS
 
@@ -79,8 +80,8 @@ will give us a loop.
 sub Prepare {
     my $self = shift;
     if (defined $self->{'TransactionObj'} &&
-	$self->{'TransactionObj'}->Type =~ /^(Comment|Correspond)$/) {
-	return undef;
+        $self->{'TransactionObj'}->Type =~ /^(Comment|Correspond)$/) {
+        return undef;
     }
     return 1;
 }
@@ -103,14 +104,14 @@ sub CreateTransaction {
     my $self = shift;
 
     my ($result, $msg) = $self->{'TemplateObj'}->Parse(
-	TicketObj => $self->{'TicketObj'});
+        TicketObj => $self->{'TicketObj'});
     return undef unless $result;
-    
+
     my ($trans, $desc, $transaction) = $self->{'TicketObj'}->Comment(
-	MIMEObj => $self->TemplateObj->MIMEObj);
+        MIMEObj => $self->TemplateObj->MIMEObj);
     $self->{'TransactionObj'} = $transaction;
 }
-    
+
 
 RT::Base->_ImportOverlays();
 
diff --git a/lib/RT/Action/RecordCorrespondence.pm b/lib/RT/Action/RecordCorrespondence.pm
index 0149f8b..5732e00 100644
--- a/lib/RT/Action/RecordCorrespondence.pm
+++ b/lib/RT/Action/RecordCorrespondence.pm
@@ -59,12 +59,12 @@ been started, to make a comment on the ticket.
 
 =head1 SYNOPSIS
 
-my $action_obj = RT::Action::RecordCorrespondence->new(
-			'TicketObj'   => $ticket_obj,
-			'TemplateObj' => $template_obj,
-			);
-my $result = $action_obj->Prepare();
-$action_obj->Commit() if $result;
+    my $action_obj = RT::Action::RecordCorrespondence->new(
+        'TicketObj'   => $ticket_obj,
+        'TemplateObj' => $template_obj,
+    );
+    my $result = $action_obj->Prepare();
+    $action_obj->Commit() if $result;
 
 =head1 METHODS
 
@@ -80,8 +80,8 @@ will give us a loop.
 sub Prepare {
     my $self = shift;
     if (defined $self->{'TransactionObj'} &&
-	$self->{'TransactionObj'}->Type =~ /^(Comment|Correspond)$/) {
-	return undef;
+        $self->{'TransactionObj'}->Type =~ /^(Comment|Correspond)$/) {
+        return undef;
     }
     return 1;
 }
@@ -104,14 +104,14 @@ sub CreateTransaction {
     my $self = shift;
 
     my ($result, $msg) = $self->{'TemplateObj'}->Parse(
-	TicketObj => $self->{'TicketObj'});
+        TicketObj => $self->{'TicketObj'});
     return undef unless $result;
-    
+
     my ($trans, $desc, $transaction) = $self->{'TicketObj'}->Correspond(
-	MIMEObj => $self->TemplateObj->MIMEObj);
+        MIMEObj => $self->TemplateObj->MIMEObj);
     $self->{'TransactionObj'} = $transaction;
 }
-    
+
 
 RT::Base->_ImportOverlays();
 
diff --git a/lib/RT/Article.pm b/lib/RT/Article.pm
index eaca9b5..33c7c66 100644
--- a/lib/RT/Article.pm
+++ b/lib/RT/Article.pm
@@ -761,10 +761,10 @@ Returns the Class Object which has the id returned by Class
 =cut
 
 sub ClassObj {
-	my $self = shift;
-	my $Class =  RT::Class->new($self->CurrentUser);
-	$Class->Load($self->Class());
-	return($Class);
+    my $self = shift;
+    my $Class =  RT::Class->new($self->CurrentUser);
+    $Class->Load($self->Class());
+    return($Class);
 }
 
 =head2 Parent
@@ -844,27 +844,27 @@ sub _CoreAccessible {
     {
      
         id =>
-		{read => 1, type => 'int(11)', default => ''},
+                {read => 1, type => 'int(11)', default => ''},
         Name => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         Summary => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         SortOrder => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         Class => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         Parent => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         URI => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         Creator => 
-		{read => 1, auto => 1, type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, type => 'int(11)', default => '0'},
         Created => 
-		{read => 1, auto => 1, type => 'datetime', default => ''},
+                {read => 1, auto => 1, type => 'datetime', default => ''},
         LastUpdatedBy => 
-		{read => 1, auto => 1, type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, type => 'int(11)', default => '0'},
         LastUpdated => 
-		{read => 1, auto => 1, type => 'datetime', default => ''},
+                {read => 1, auto => 1, type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Attachment.pm b/lib/RT/Attachment.pm
index f0509a0..1a0909b 100644
--- a/lib/RT/Attachment.pm
+++ b/lib/RT/Attachment.pm
@@ -503,9 +503,9 @@ sub NiceHeaders {
     my $hdrs = "";
     my @hdrs = $self->_SplitHeaders;
     while (my $str = shift @hdrs) {
-	    next unless $str =~ /^(To|From|RT-Send-Cc|Cc|Bcc|Date|Subject):/i;
-	    $hdrs .= $str . "\n";
-	    $hdrs .= shift( @hdrs ) . "\n" while ($hdrs[0] =~ /^[ \t]+/);
+        next unless $str =~ /^(To|From|RT-Send-Cc|Cc|Bcc|Date|Subject):/i;
+        $hdrs .= $str . "\n";
+        $hdrs .= shift( @hdrs ) . "\n" while ($hdrs[0] =~ /^[ \t]+/);
     }
     return $hdrs;
 }
@@ -999,29 +999,29 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         TransactionId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Parent =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         MessageId =>
-		{read => 1, write => 1, sql_type => 12, length => 160,  is_blob => 0,  is_numeric => 0,  type => 'varchar(160)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 160,  is_blob => 0,  is_numeric => 0,  type => 'varchar(160)', default => ''},
         Subject =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         Filename =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         ContentType =>
-		{read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
         ContentEncoding =>
-		{read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
         Content =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'longblob', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'longblob', default => ''},
         Headers =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'longtext', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'longtext', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Attachments.pm b/lib/RT/Attachments.pm
index e28bf9b..bfcc29a 100644
--- a/lib/RT/Attachments.pm
+++ b/lib/RT/Attachments.pm
@@ -132,9 +132,9 @@ sub ContentType  {
     my $self = shift;
     my %args = (
         VALUE           => 'text/plain',
-	    OPERATOR        => '=',
-	    ENTRYAGGREGATOR => 'OR',
-	    @_
+        OPERATOR        => '=',
+        ENTRYAGGREGATOR => 'OR',
+        @_
     );
 
     return $self->Limit ( %args, FIELD => 'ContentType' );
diff --git a/lib/RT/Attribute.pm b/lib/RT/Attribute.pm
index fd99100..9a7f175 100644
--- a/lib/RT/Attribute.pm
+++ b/lib/RT/Attribute.pm
@@ -145,11 +145,11 @@ sub Create {
                 Content => '',
                 ContentType => '',
                 Object => undef,
-		  @_);
+                @_);
 
     if ($args{Object} and UNIVERSAL::can($args{Object}, 'Id')) {
-	    $args{ObjectType} = ref($args{Object});
-	    $args{ObjectId} = $args{Object}->Id;
+        $args{ObjectType} = ref($args{Object});
+        $args{ObjectId} = $args{Object}->Id;
     } else {
         return(0, $self->loc("Required parameter '[_1]' not specified", 'Object'));
 
@@ -212,11 +212,11 @@ sub LoadByNameAndObject {
     );
 
     return (
-	$self->LoadByCols(
-	    Name => $args{'Name'},
-	    ObjectType => ref($args{'Object'}),
-	    ObjectId => $args{'Object'}->Id,
-	)
+        $self->LoadByCols(
+            Name => $args{'Name'},
+            ObjectType => ref($args{'Object'}),
+            ObjectId => $args{'Object'}->Id,
+        )
     );
 
 }
@@ -609,27 +609,27 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Name =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         Description =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         Content =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'blob', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'blob', default => ''},
         ContentType =>
-		{read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
         ObjectType =>
-		{read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/CachedGroupMember.pm b/lib/RT/CachedGroupMember.pm
index 4c05852..6b0b3a8 100644
--- a/lib/RT/CachedGroupMember.pm
+++ b/lib/RT/CachedGroupMember.pm
@@ -418,17 +418,17 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         GroupId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         MemberId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Via =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         ImmediateParentId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Disabled =>
-		{read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
+                {read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
 
  }
 };
diff --git a/lib/RT/CachedGroupMembers.pm b/lib/RT/CachedGroupMembers.pm
index 21f3a5c..f2942bc 100644
--- a/lib/RT/CachedGroupMembers.pm
+++ b/lib/RT/CachedGroupMembers.pm
@@ -165,7 +165,7 @@ sub LimitToGroupsWithMember {
                          VALUE => $member || '0',
                          FIELD => 'MemberId',
                          ENTRYAGGREGATOR => 'OR',
-			            QUOTEVALUE => 0
+                         QUOTEVALUE => 0
                          ));
 
 }
diff --git a/lib/RT/Class.pm b/lib/RT/Class.pm
index 2bed9c3..1d4aeb0 100644
--- a/lib/RT/Class.pm
+++ b/lib/RT/Class.pm
@@ -617,25 +617,25 @@ sub _CoreAccessible {
     {
      
         id =>
-		{read => 1, type => 'int(11)', default => ''},
+                {read => 1, type => 'int(11)', default => ''},
         Name => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         Description => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         SortOrder => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         Disabled => 
-		{read => 1, write => 1, type => 'int(2)', default => '0'},
+                {read => 1, write => 1, type => 'int(2)', default => '0'},
         HotList => 
-		{read => 1, write => 1, type => 'int(2)', default => '0'},
+                {read => 1, write => 1, type => 'int(2)', default => '0'},
         Creator => 
-		{read => 1, auto => 1, type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, type => 'int(11)', default => '0'},
         Created => 
-		{read => 1, auto => 1, type => 'datetime', default => ''},
+                {read => 1, auto => 1, type => 'datetime', default => ''},
         LastUpdatedBy => 
-		{read => 1, auto => 1, type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, type => 'int(11)', default => '0'},
         LastUpdated => 
-		{read => 1, auto => 1, type => 'datetime', default => ''},
+                {read => 1, auto => 1, type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Condition.pm b/lib/RT/Condition.pm
index 3ca4f96..70f1fd5 100644
--- a/lib/RT/Condition.pm
+++ b/lib/RT/Condition.pm
@@ -54,14 +54,14 @@
 
     use RT::Condition;
     my $foo = RT::Condition->new( 
-		TransactionObj => $tr, 
-		TicketObj => $ti, 
-		ScripObj => $scr, 
-		Argument => $arg, 
-		Type => $type);
+                TransactionObj => $tr, 
+                TicketObj => $ti, 
+                ScripObj => $scr, 
+                Argument => $arg, 
+                Type => $type);
 
     if ($foo->IsApplicable) {
- 	   # do something
+           # do something
     }
 
 
@@ -95,14 +95,14 @@ sub new  {
 sub _Init  {
   my $self = shift;
   my %args = ( TransactionObj => undef,
-	       TicketObj => undef,
-	       ScripObj => undef,
-	       TemplateObj => undef,
-	       Argument => undef,
-	       ApplicableTransTypes => undef,
+               TicketObj => undef,
+               ScripObj => undef,
+               TemplateObj => undef,
+               Argument => undef,
+               ApplicableTransTypes => undef,
            CurrentUser => undef,
-	       @_ );
-  
+               @_ );
+
   $self->{'Argument'} = $args{'Argument'};
   $self->{'ScripObj'} = $args{'ScripObj'};
   $self->{'TicketObj'} = $args{'TicketObj'};
diff --git a/lib/RT/Condition/BeforeDue.pm b/lib/RT/Condition/BeforeDue.pm
index 9845c63..2e0495a 100644
--- a/lib/RT/Condition/BeforeDue.pm
+++ b/lib/RT/Condition/BeforeDue.pm
@@ -61,8 +61,8 @@ sub IsApplicable {
     # and 3 minutes and 4 seconds.
     my %e;
     foreach (qw(d h m s)) {
-	my @vals = $self->Argument =~ m/(\d+)$_/;
-	$e{$_} = pop @vals || 0;
+        my @vals = $self->Argument =~ m/(\d+)$_/;
+        $e{$_} = pop @vals || 0;
     }
     my $elapse = $e{'d'} * 24*60*60 + $e{'h'} * 60*60 + $e{'m'} * 60 + $e{'s'};
 
diff --git a/lib/RT/Condition/Overdue.pm b/lib/RT/Condition/Overdue.pm
index 0b66a57..635a877 100644
--- a/lib/RT/Condition/Overdue.pm
+++ b/lib/RT/Condition/Overdue.pm
@@ -71,11 +71,11 @@ If the due date is before "now" return true
 sub IsApplicable {
     my $self = shift;
     if ($self->TicketObj->DueObj->Unix > 0 and
-	$self->TicketObj->DueObj->Unix < time())  {
-	return(1);
-    } 
+        $self->TicketObj->DueObj->Unix < time())  {
+        return(1);
+    }
     else {
-	return(undef);
+        return(undef);
     }
 }
 
diff --git a/lib/RT/Condition/OwnerChange.pm b/lib/RT/Condition/OwnerChange.pm
index d036d78..93c6aa8 100644
--- a/lib/RT/Condition/OwnerChange.pm
+++ b/lib/RT/Condition/OwnerChange.pm
@@ -63,10 +63,10 @@ If we're changing the owner return true, otherwise return false
 sub IsApplicable {
     my $self = shift;
     if ( ( $self->TransactionObj->Field || '' ) eq 'Owner' ) {
-	return(1);
-    } 
+        return(1);
+    }
     else {
-	return(undef);
+        return(undef);
     }
 }
 
diff --git a/lib/RT/Condition/PriorityChange.pm b/lib/RT/Condition/PriorityChange.pm
index 96e3392..a12438d 100644
--- a/lib/RT/Condition/PriorityChange.pm
+++ b/lib/RT/Condition/PriorityChange.pm
@@ -62,10 +62,10 @@ the Priority Obj
 sub IsApplicable {
     my $self = shift;
     if ($self->TransactionObj->Field eq 'Priority') {
-	return(1);
-    } 
+        return(1);
+    }
     else {
-	return(undef);
+        return(undef);
     }
 }
 
diff --git a/lib/RT/Condition/PriorityExceeds.pm b/lib/RT/Condition/PriorityExceeds.pm
index 3e57c48..ebbeb87 100644
--- a/lib/RT/Condition/PriorityExceeds.pm
+++ b/lib/RT/Condition/PriorityExceeds.pm
@@ -60,10 +60,10 @@ If the priority exceeds the argument value
 sub IsApplicable {
     my $self = shift;
     if ($self->TicketObj->Priority > $self->Argument)  {
-	return(1);
-    } 
+        return(1);
+    }
     else {
-	return(undef);
+        return(undef);
     }
 }
 
diff --git a/lib/RT/Condition/QueueChange.pm b/lib/RT/Condition/QueueChange.pm
index 869d2b6..d04e095 100644
--- a/lib/RT/Condition/QueueChange.pm
+++ b/lib/RT/Condition/QueueChange.pm
@@ -60,10 +60,10 @@ If the queue has changed.
 sub IsApplicable {
     my $self = shift;
     if ($self->TransactionObj->Field eq 'Queue') {
-	    return(1);
-    } 
+        return(1);
+    }
     else {
-	    return(undef);
+        return(undef);
     }
 }
 
diff --git a/lib/RT/CustomFieldValues.pm b/lib/RT/CustomFieldValues.pm
index 008cc45..10a8e5c 100644
--- a/lib/RT/CustomFieldValues.pm
+++ b/lib/RT/CustomFieldValues.pm
@@ -62,15 +62,15 @@ sub _Init {
 
   # By default, order by SortOrder
   $self->OrderByCols(
-	 { ALIAS => 'main',
-	   FIELD => 'SortOrder',
-	   ORDER => 'ASC' },
-	 { ALIAS => 'main',
-	   FIELD => 'Name',
-	   ORDER => 'ASC' },
-	 { ALIAS => 'main',
-	   FIELD => 'id',
-	   ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'SortOrder',
+           ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'Name',
+           ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'id',
+           ORDER => 'ASC' },
      );
 
     return ( $self->SUPER::_Init(@_) );
diff --git a/lib/RT/CustomFields.pm b/lib/RT/CustomFields.pm
index a7d96b0..5b9affb 100644
--- a/lib/RT/CustomFields.pm
+++ b/lib/RT/CustomFields.pm
@@ -81,15 +81,15 @@ sub _Init {
 
   # By default, order by SortOrder
   $self->OrderByCols(
-	 { ALIAS => 'main',
-	   FIELD => 'SortOrder',
-	   ORDER => 'ASC' },
-	 { ALIAS => 'main',
-	   FIELD => 'Name',
-	   ORDER => 'ASC' },
-	 { ALIAS => 'main',
-	   FIELD => 'id',
-	   ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'SortOrder',
+           ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'Name',
+           ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'id',
+           ORDER => 'ASC' },
      );
     $self->{'with_disabled_column'} = 1;
 
@@ -209,12 +209,12 @@ sub LimitToGlobalOrObjectId {
 
 
     foreach my $id (@_) {
-	$self->Limit( ALIAS           => $self->_OCFAlias,
-		    FIELD           => 'ObjectId',
-		    OPERATOR        => '=',
-		    VALUE           => $id || 0,
-		    ENTRYAGGREGATOR => 'OR' );
-	$global_only = 0 if $id;
+        $self->Limit( ALIAS           => $self->_OCFAlias,
+                    FIELD           => 'ObjectId',
+                    OPERATOR        => '=',
+                    VALUE           => $id || 0,
+                    ENTRYAGGREGATOR => 'OR' );
+        $global_only = 0 if $id;
     }
 
     $self->Limit( ALIAS           => $self->_OCFAlias,
@@ -305,8 +305,8 @@ sub LimitToGlobal  {
 
   $self->Limit (ALIAS => $self->_OCFAlias,
                 ENTRYAGGREGATOR => 'OR',
-		FIELD => 'ObjectId',
-		VALUE => 0);
+                FIELD => 'ObjectId',
+                VALUE => 0);
   $self->LimitToLookupType( 'RT::Queue-RT::Ticket' );
 }
 
diff --git a/lib/RT/Group.pm b/lib/RT/Group.pm
index 3e7ace9..849fef4 100644
--- a/lib/RT/Group.pm
+++ b/lib/RT/Group.pm
@@ -1027,8 +1027,8 @@ sub AddMember {
     # to modify group membership or the user is the principal in question
     # and the user has the right to modify his own membership
     unless ( ($new_member == $self->CurrentUser->PrincipalId &&
-	      $self->CurrentUserHasRight('ModifyOwnMembership') ) ||
-	      $self->CurrentUserHasRight('AdminGroupMembership') ) {
+              $self->CurrentUserHasRight('ModifyOwnMembership') ) ||
+              $self->CurrentUserHasRight('AdminGroupMembership') ) {
         #User has no permission to be doing this
         return ( 0, $self->loc("Permission Denied") );
     }
@@ -1040,7 +1040,7 @@ sub AddMember {
 # this should _ONLY_ ever be called from Ticket/Queue AddWatcher
 # when we want to deal with groups according to queue rights
 # In the dim future, this will all get factored out and life
-# will get better	
+# will get better
 
 # takes a paramhash of { PrincipalId => undef, InsideTransaction }
 
@@ -1225,8 +1225,8 @@ sub DeleteMember {
     # and the user has the right to modify his own membership
 
     unless ( (($member_id == $self->CurrentUser->PrincipalId) &&
-	      $self->CurrentUserHasRight('ModifyOwnMembership') ) ||
-	      $self->CurrentUserHasRight('AdminGroupMembership') ) {
+              $self->CurrentUserHasRight('ModifyOwnMembership') ) ||
+              $self->CurrentUserHasRight('AdminGroupMembership') ) {
         #User has no permission to be doing this
         return ( 0, $self->loc("Permission Denied") );
     }
@@ -1237,7 +1237,7 @@ sub DeleteMember {
 # this should _ONLY_ ever be called from Ticket/Queue  DeleteWatcher
 # when we want to deal with groups according to queue rights
 # In the dim future, this will all get factored out and life
-# will get better	
+# will get better
 
 sub _DeleteMember {
     my $self = shift;
@@ -1278,20 +1278,20 @@ sub _Set {
     my %args = (
         Field => undef,
         Value => undef,
-	TransactionType   => 'Set',
-	RecordTransaction => 1,
+        TransactionType   => 'Set',
+        RecordTransaction => 1,
         @_
     );
 
     unless ( $self->CurrentUserHasRight('AdminGroup') ) {
-      	return ( 0, $self->loc('Permission Denied') );
-	}
+        return ( 0, $self->loc('Permission Denied') );
+        }
 
     my $Old = $self->SUPER::_Value("$args{'Field'}");
-    
+
     my ($ret, $msg) = $self->SUPER::_Set( Field => $args{'Field'},
-					  Value => $args{'Value'} );
-    
+                                          Value => $args{'Value'} );
+
     #If we can't actually set the field to the value, don't record
     # a transaction. instead, get out of here.
     if ( $ret == 0 ) { return ( 0, $msg ); }
@@ -1332,13 +1332,13 @@ sub CurrentUserHasRight {
 
 
 
-    if ($self->Id && 
-		$self->CurrentUser->HasRight( Object => $self,
-										   Right => $right )) {
+    if ($self->Id &&
+                $self->CurrentUser->HasRight( Object => $self,
+                                              Right => $right )) {
         return(1);
-   }
+    }
     elsif ( $self->CurrentUser->HasRight(Object => $RT::System, Right =>  $right )) {
-		return (1);
+        return (1);
     } else {
         return(undef);
     }
@@ -1400,8 +1400,8 @@ sub PrincipalId {
 
 sub BasicColumns {
     (
-	[ Name => 'Name' ],
-	[ Description => 'Description' ],
+        [ Name => 'Name' ],
+        [ Description => 'Description' ],
     );
 }
 
@@ -1560,25 +1560,25 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Name =>
-		{read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => ''},
         Description =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         Domain =>
-		{read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
         Type =>
-		{read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
         Instance =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/GroupMember.pm b/lib/RT/GroupMember.pm
index 8df4a73..c62130f 100644
--- a/lib/RT/GroupMember.pm
+++ b/lib/RT/GroupMember.pm
@@ -470,19 +470,19 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         GroupId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         MemberId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/GroupMembers.pm b/lib/RT/GroupMembers.pm
index 0d2cefb..65880a0 100644
--- a/lib/RT/GroupMembers.pm
+++ b/lib/RT/GroupMembers.pm
@@ -142,7 +142,7 @@ sub LimitToMembersOfGroup {
                          VALUE => $group,
                          FIELD => 'GroupId',
                          ENTRYAGGREGATOR => 'OR',
-			             QUOTEVALUE => 0
+                         QUOTEVALUE => 0
                          ));
 
 }
diff --git a/lib/RT/Groups.pm b/lib/RT/Groups.pm
index 0c9ef3c..5217f14 100644
--- a/lib/RT/Groups.pm
+++ b/lib/RT/Groups.pm
@@ -95,8 +95,8 @@ sub _Init {
   my @result = $self->SUPER::_Init(@_);
 
   $self->OrderBy( ALIAS => 'main',
-		  FIELD => 'Name',
-		  ORDER => 'ASC');
+                  FIELD => 'Name',
+                  ORDER => 'ASC');
 
   # XXX: this code should be generalized
   $self->{'princalias'} = $self->Join(
@@ -465,14 +465,14 @@ sub Next {
 
     my $Group = $self->SUPER::Next();
     if ((defined($Group)) and (ref($Group))) {
-	unless ($Group->CurrentUserHasRight('SeeGroup')) {
-	    return $self->Next();
-	}
-	
-	return $Group;
+        unless ($Group->CurrentUserHasRight('SeeGroup')) {
+            return $self->Next();
+        }
+
+        return $Group;
     }
     else {
-	return undef;
+        return undef;
     }
 }
 
@@ -480,14 +480,14 @@ sub Next {
 
 sub _DoSearch {
     my $self = shift;
-    
+
     #unless we really want to find disabled rows, make sure we're only finding enabled ones.
     unless($self->{'find_disabled_rows'}) {
-	$self->LimitToEnabled();
+        $self->LimitToEnabled();
     }
-    
+
     return($self->SUPER::_DoSearch(@_));
-    
+
 }
 
 
diff --git a/lib/RT/I18N.pm b/lib/RT/I18N.pm
index b5a5a7a..7a9bee7 100644
--- a/lib/RT/I18N.pm
+++ b/lib/RT/I18N.pm
@@ -225,14 +225,14 @@ sub SetMIMEEntityToEncoding {
     }
 
     SetMIMEHeadToEncoding(
-	$head,
-	_FindOrGuessCharset($entity, 1) => $enc,
-	$preserve_words
+        $head,
+        _FindOrGuessCharset($entity, 1) => $enc,
+        $preserve_words
     );
 
     # If this is a textual entity, we'd need to preserve its original encoding
     $head->replace( "X-RT-Original-Encoding" => $charset )
-	if $head->mime_attr('content-type.charset') or IsTextualContentType($head->mime_type);
+        if $head->mime_attr('content-type.charset') or IsTextualContentType($head->mime_type);
 
     return unless IsTextualContentType($head->mime_type);
 
@@ -347,7 +347,7 @@ sub DecodeMIMEWordsToEncoding {
 
             if ( $encoding eq 'q' ) {
                 use MIME::QuotedPrint;
-                $enc_str =~ tr/_/ /;		# Observed from Outlook Express
+                $enc_str =~ tr/_/ /;                # Observed from Outlook Express
                 $enc_str = decode_qp($enc_str);
             } elsif ( $encoding eq 'b' ) {
                 use MIME::Base64;
@@ -468,7 +468,7 @@ sub _GuessCharset {
             }
         }
         else {
-	    $RT::Logger->error(
+            $RT::Logger->error(
                 "You requested to guess encoding, but we couldn't"
                 ." load Encode::Detect::Detector module"
             );
diff --git a/lib/RT/Interface/CLI.pm b/lib/RT/Interface/CLI.pm
index 0f2d90e..838226f 100644
--- a/lib/RT/Interface/CLI.pm
+++ b/lib/RT/Interface/CLI.pm
@@ -62,8 +62,8 @@ our @EXPORT_OK = qw(CleanEnv GetCurrentUser GetMessageContent debug loc);
 
   use lib "/path/to/rt/libraries/";
 
-  use RT::Interface::CLI  qw(CleanEnv 
-	  		   GetCurrentUser GetMessageContent loc);
+  use RT::Interface::CLI  qw(CleanEnv
+                             GetCurrentUser GetMessageContent loc);
 
   #Clean out all the nasties from the environment
   CleanEnv();
@@ -102,7 +102,7 @@ sub CleanEnv {
     $ENV{'CDPATH'} = '' if defined $ENV{'CDPATH'};
     $ENV{'SHELL'} = '/bin/sh' if defined $ENV{'SHELL'};
     $ENV{'ENV'} = '' if defined $ENV{'ENV'};
-    $ENV{'IFS'} = ''		if defined $ENV{'IFS'};
+    $ENV{'IFS'} = '' if defined $ENV{'IFS'};
 }
 
 
@@ -135,7 +135,7 @@ sub GetCurrentUser  {
     $CurrentUser->LoadByGecos($Gecos);
     
     unless ($CurrentUser->Id) {
-	$RT::Logger->debug("No user with a unix login of '$Gecos' was found. ");
+        $RT::Logger->debug("No user with a unix login of '$Gecos' was found. ");
     }
 
     return($CurrentUser);
@@ -168,54 +168,54 @@ array of lines.
 
 sub GetMessageContent {
     my %args = (  Source => undef,
-		  Content => undef,
-		  Edit => undef,
-		  CurrentUser => undef,
-		 @_);
+                  Content => undef,
+                  Edit => undef,
+                  CurrentUser => undef,
+                 @_);
     my $source = $args{'Source'};
 
     my $edit = $args{'Edit'};
-    
+
     my $currentuser = $args{'CurrentUser'};
     my @lines;
 
     use File::Temp qw/ tempfile/;
-    
+
     #Load the sourcefile, if it's been handed to us
     if ($source) {
-	open( SOURCE, '<', $source ) or die $!;
-	@lines = (<SOURCE>) or die $!;
-	close (SOURCE) or die $!;
+        open( SOURCE, '<', $source ) or die $!;
+        @lines = (<SOURCE>) or die $!;
+        close (SOURCE) or die $!;
     }
     elsif ($args{'Content'}) {
-	@lines = split('\n',$args{'Content'});
+        @lines = split('\n',$args{'Content'});
     }
     #get us a tempfile.
     my ($fh, $filename) = tempfile();
-	
+
     #write to a tmpfile
     for (@lines) {
-	print $fh $_;
+        print $fh $_;
     }
     close ($fh) or die $!;
-    
+
     #Edit the file if we need to
-    if ($edit) {	
-
-	unless ($ENV{'EDITOR'}) {
-	    $RT::Logger->crit('No $EDITOR variable defined');
-	    return undef;
-	}
-	system ($ENV{'EDITOR'}, $filename);
-    }	
-    
+    if ($edit) {
+
+        unless ($ENV{'EDITOR'}) {
+            $RT::Logger->crit('No $EDITOR variable defined');
+            return undef;
+        }
+        system ($ENV{'EDITOR'}, $filename);
+    }
+
     open( READ, '<', $filename ) or die $!;
     my @newlines = (<READ>);
     close (READ) or die $!;
 
     unlink ($filename) unless (debug());
     return(\@newlines);
-    
+
 }
 
 
@@ -224,14 +224,14 @@ sub debug {
     my $val = shift;
     my ($debug);
     if ($val) {
-	$RT::Logger->debug($val);
-	if ($debug) {
-	    print STDERR "$val\n";
-	}
+        $RT::Logger->debug($val);
+        if ($debug) {
+            print STDERR "$val\n";
+        }
     }
     if ($debug) {
-	return(1);
-    }	
+        return(1);
+    }
 }
 
 sub ShowHelp {
diff --git a/lib/RT/Link.pm b/lib/RT/Link.pm
index 0f9fa9f..3d7c5a4 100644
--- a/lib/RT/Link.pm
+++ b/lib/RT/Link.pm
@@ -154,30 +154,30 @@ sub Create {
     $base->FromURI( $args{'Base'} );
 
     unless ( $base->Resolver && $base->Scheme ) {
-	my $msg = $self->loc("Couldn't resolve base '[_1]' into a URI.", 
-			     $args{'Base'});
+        my $msg = $self->loc("Couldn't resolve base '[_1]' into a URI.", 
+                             $args{'Base'});
         $RT::Logger->warning( "$self $msg" );
 
-	if (wantarray) {
-	    return(undef, $msg);
-	} else {
-	    return (undef);
-	}
+        if (wantarray) {
+            return(undef, $msg);
+        } else {
+            return (undef);
+        }
     }
 
     my $target = RT::URI->new( $self->CurrentUser );
     $target->FromURI( $args{'Target'} );
 
     unless ( $target->Resolver ) {
-	my $msg = $self->loc("Couldn't resolve target '[_1]' into a URI.", 
-			     $args{'Target'});
+        my $msg = $self->loc("Couldn't resolve target '[_1]' into a URI.", 
+                             $args{'Target'});
         $RT::Logger->warning( "$self $msg" );
 
-	if (wantarray) {
-	    return(undef, $msg);
-	} else {
-	    return (undef);
-	}
+        if (wantarray) {
+            return(undef, $msg);
+        } else {
+            return (undef);
+        }
     }
 
     my $base_id   = 0;
@@ -477,25 +477,25 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Base =>
-		{read => 1, write => 1, sql_type => 12, length => 240,  is_blob => 0,  is_numeric => 0,  type => 'varchar(240)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 240,  is_blob => 0,  is_numeric => 0,  type => 'varchar(240)', default => ''},
         Target =>
-		{read => 1, write => 1, sql_type => 12, length => 240,  is_blob => 0,  is_numeric => 0,  type => 'varchar(240)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 240,  is_blob => 0,  is_numeric => 0,  type => 'varchar(240)', default => ''},
         Type =>
-		{read => 1, write => 1, sql_type => 12, length => 20,  is_blob => 0,  is_numeric => 0,  type => 'varchar(20)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 20,  is_blob => 0,  is_numeric => 0,  type => 'varchar(20)', default => ''},
         LocalTarget =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LocalBase =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Links.pm b/lib/RT/Links.pm
index 52b8c8d..32bf8c7 100644
--- a/lib/RT/Links.pm
+++ b/lib/RT/Links.pm
@@ -82,27 +82,27 @@ use RT::URI;
 sub Limit  {
     my $self = shift;
     my %args = ( ENTRYAGGREGATOR => 'AND',
-		 OPERATOR => '=',
-		 @_);
+                 OPERATOR => '=',
+                 @_);
 
     # If we're limiting by target, order by base
     # (Order by the thing that's changing)
 
-    if ( ($args{'FIELD'} eq 'Target') or 
-	 ($args{'FIELD'} eq 'LocalTarget') ) {
-	$self->OrderByCols(
+    if ( ($args{'FIELD'} eq 'Target') or
+         ($args{'FIELD'} eq 'LocalTarget') ) {
+        $self->OrderByCols(
             { ALIAS => 'main', FIELD => 'LocalBase', ORDER => 'ASC' },
             { ALIAS => 'main', FIELD => 'Base', ORDER => 'ASC' },
         );
     }
-    elsif ( ($args{'FIELD'} eq 'Base') or 
-	    ($args{'FIELD'} eq 'LocalBase') ) {
-	$self->OrderByCols(
+    elsif ( ($args{'FIELD'} eq 'Base') or
+            ($args{'FIELD'} eq 'LocalBase') ) {
+        $self->OrderByCols(
             { ALIAS => 'main', FIELD => 'LocalTarget', ORDER => 'ASC' },
             { ALIAS => 'main', FIELD => 'Target', ORDER => 'ASC' },
         );
     }
-    
+
 
     $self->SUPER::Limit(%args);
 }
diff --git a/lib/RT/ObjectClass.pm b/lib/RT/ObjectClass.pm
index e1c66da..48cda9d 100644
--- a/lib/RT/ObjectClass.pm
+++ b/lib/RT/ObjectClass.pm
@@ -114,10 +114,10 @@ Returns the Class Object which has the id returned by Class
 =cut
 
 sub ClassObj {
-	my $self = shift;
-	my $Class =  RT::Class->new($self->CurrentUser);
-	$Class->Load($self->Class());
-	return($Class);
+    my $self = shift;
+    my $Class =  RT::Class->new($self->CurrentUser);
+    $Class->Load($self->Class());
+    return($Class);
 }
 
 =head2 ObjectType
@@ -197,21 +197,21 @@ sub _CoreAccessible {
     {
      
         id =>
-		{read => 1, type => 'int(11)', default => ''},
+                {read => 1, type => 'int(11)', default => ''},
         Class => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         ObjectType => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         ObjectId => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         Creator => 
-		{read => 1, auto => 1, type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, type => 'int(11)', default => '0'},
         Created => 
-		{read => 1, auto => 1, type => 'datetime', default => ''},
+                {read => 1, auto => 1, type => 'datetime', default => ''},
         LastUpdatedBy => 
-		{read => 1, auto => 1, type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, type => 'int(11)', default => '0'},
         LastUpdated => 
-		{read => 1, auto => 1, type => 'datetime', default => ''},
+                {read => 1, auto => 1, type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/ObjectCustomField.pm b/lib/RT/ObjectCustomField.pm
index 9ecf36e..2bb91a7 100644
--- a/lib/RT/ObjectCustomField.pm
+++ b/lib/RT/ObjectCustomField.pm
@@ -205,21 +205,21 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         CustomField =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         SortOrder =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/ObjectCustomFieldValue.pm b/lib/RT/ObjectCustomFieldValue.pm
index 3da79bc..97adab2 100644
--- a/lib/RT/ObjectCustomFieldValue.pm
+++ b/lib/RT/ObjectCustomFieldValue.pm
@@ -720,33 +720,33 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         CustomField =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         ObjectType =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         SortOrder =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Content =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         LargeContent =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'longblob', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'longblob', default => ''},
         ContentType =>
-		{read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
         ContentEncoding =>
-		{read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 80,  is_blob => 0,  is_numeric => 0,  type => 'varchar(80)', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Disabled =>
-		{read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
+                {read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
 
  }
 };
diff --git a/lib/RT/ObjectCustomFieldValues.pm b/lib/RT/ObjectCustomFieldValues.pm
index decee02..e96d126 100644
--- a/lib/RT/ObjectCustomFieldValues.pm
+++ b/lib/RT/ObjectCustomFieldValues.pm
@@ -62,12 +62,12 @@ sub _Init {
 
   # By default, order by SortOrder
   $self->OrderByCols(
-	 { ALIAS => 'main',
-	   FIELD => 'SortOrder',
-	   ORDER => 'ASC' },
-	 { ALIAS => 'main',
-	   FIELD => 'id',
-	   ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'SortOrder',
+           ORDER => 'ASC' },
+         { ALIAS => 'main',
+           FIELD => 'id',
+           ORDER => 'ASC' },
      );
 
     return ( $self->SUPER::_Init(@_) );
diff --git a/lib/RT/ObjectCustomFields.pm b/lib/RT/ObjectCustomFields.pm
index f39adac..16cc4b8 100644
--- a/lib/RT/ObjectCustomFields.pm
+++ b/lib/RT/ObjectCustomFields.pm
@@ -87,13 +87,13 @@ sub HasEntryForCustomField {
     my @items = grep {$_->CustomField == $id } @{$self->ItemsArrayRef};
 
     if ($#items > 1) {
-	die "$self HasEntry had a list with more than one of $id in it. this can never happen";
+        die "$self HasEntry had a list with more than one of $id in it. this can never happen";
     }
     if ($#items == -1 ) {
-	return undef;
+        return undef;
     }
     else {
-	return ($items[0]);
+        return ($items[0]);
     }  
 }
 
diff --git a/lib/RT/ObjectScrip.pm b/lib/RT/ObjectScrip.pm
index 1a8990f..92cbbbf 100644
--- a/lib/RT/ObjectScrip.pm
+++ b/lib/RT/ObjectScrip.pm
@@ -226,23 +226,23 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Scrip =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Stage =>
-		{read => 1, write => 1, sql_type => 12, length => 32,  is_blob => 0,  is_numeric => 0,  type => 'varchar(32)', default => 'TransactionCreate'},
+                {read => 1, write => 1, sql_type => 12, length => 32,  is_blob => 0,  is_numeric => 0,  type => 'varchar(32)', default => 'TransactionCreate'},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         SortOrder =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/ObjectTopic.pm b/lib/RT/ObjectTopic.pm
index ac577ae..bdb5cbc 100644
--- a/lib/RT/ObjectTopic.pm
+++ b/lib/RT/ObjectTopic.pm
@@ -93,18 +93,16 @@ Create takes a hash of values and creates a row in the database:
 
 sub Create {
     my $self = shift;
-    my %args = ( 
+    my %args = (
                 Topic => '0',
                 ObjectType => '',
                 ObjectId => '0',
-
-		  @_);
+                @_);
     $self->SUPER::Create(
                          Topic => $args{'Topic'},
                          ObjectType => $args{'ObjectType'},
                          ObjectId => $args{'ObjectId'},
-);
-
+                     );
 }
 
 
@@ -144,10 +142,10 @@ Returns the Topic Object which has the id returned by Topic
 =cut
 
 sub TopicObj {
-	my $self = shift;
-	my $Topic =  RT::Topic->new($self->CurrentUser);
-	$Topic->Load($self->Topic());
-	return($Topic);
+    my $self = shift;
+    my $Topic =  RT::Topic->new($self->CurrentUser);
+    $Topic->Load($self->Topic());
+    return($Topic);
 }
 
 =head2 ObjectType
@@ -189,15 +187,14 @@ Returns (1, 'Status message') on success and (0, 'Error Message') on failure.
 
 sub _CoreAccessible {
     {
-     
         id =>
-		{read => 1, type => 'int(11)', default => ''},
+                {read => 1, type => 'int(11)', default => ''},
         Topic => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
         ObjectType => 
-		{read => 1, write => 1, type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, type => 'varchar(64)', default => ''},
         ObjectId => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
 
  }
 };
diff --git a/lib/RT/ObjectTopics.pm b/lib/RT/ObjectTopics.pm
index 1ffb146..1623931 100644
--- a/lib/RT/ObjectTopics.pm
+++ b/lib/RT/ObjectTopics.pm
@@ -69,8 +69,8 @@ sub LimitToTopic {
     my $self = shift;
     my $cf = shift;
     return ($self->Limit( FIELD => 'Topic',
-			  VALUE => $cf,
-			  OPERATOR => '='));
+                          VALUE => $cf,
+                          OPERATOR => '='));
 
 }
 
@@ -90,7 +90,7 @@ sub LimitToObject {
     my $object = shift;
 
     $self->Limit( FIELD => 'ObjectType',
-		  VALUE => ref($object));
+                  VALUE => ref($object));
     $self->Limit( FIELD => 'ObjectId',
                   VALUE => $object->Id);
 
diff --git a/lib/RT/Principal.pm b/lib/RT/Principal.pm
index 450d89b..afb651f 100644
--- a/lib/RT/Principal.pm
+++ b/lib/RT/Principal.pm
@@ -809,13 +809,13 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         PrincipalType =>
-		{read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Disabled =>
-		{read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
+                {read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
 
  }
 };
diff --git a/lib/RT/Queue.pm b/lib/RT/Queue.pm
index a2a87c1..9a0a7f3 100644
--- a/lib/RT/Queue.pm
+++ b/lib/RT/Queue.pm
@@ -572,8 +572,8 @@ sub TicketCustomFields {
     my $cfs = RT::CustomFields->new( $self->CurrentUser );
     if ( $self->CurrentUserHasRight('SeeQueue') ) {
         $cfs->SetContextObject( $self );
-	$cfs->LimitToGlobalOrObjectId( $self->Id );
-	$cfs->LimitToLookupType( 'RT::Queue-RT::Ticket' );
+        $cfs->LimitToGlobalOrObjectId( $self->Id );
+        $cfs->LimitToLookupType( 'RT::Queue-RT::Ticket' );
         $cfs->ApplySortOrder;
     }
     return ($cfs);
@@ -594,8 +594,8 @@ sub TicketTransactionCustomFields {
     my $cfs = RT::CustomFields->new( $self->CurrentUser );
     if ( $self->CurrentUserHasRight('SeeQueue') ) {
         $cfs->SetContextObject( $self );
-	$cfs->LimitToGlobalOrObjectId( $self->Id );
-	$cfs->LimitToLookupType( 'RT::Queue-RT::Ticket-RT::Transaction' );
+        $cfs->LimitToGlobalOrObjectId( $self->Id );
+        $cfs->LimitToLookupType( 'RT::Queue-RT::Ticket-RT::Transaction' );
         $cfs->ApplySortOrder;
     }
     return ($cfs);
diff --git a/lib/RT/Queues.pm b/lib/RT/Queues.pm
index 551b70c..6e67bda 100644
--- a/lib/RT/Queues.pm
+++ b/lib/RT/Queues.pm
@@ -82,8 +82,8 @@ sub _Init {
 
   # By default, order by name
   $self->OrderBy( ALIAS => 'main',
-		  FIELD => 'Name',
-		  ORDER => 'ASC');
+                  FIELD => 'Name',
+                  ORDER => 'ASC');
 
   return ($self->SUPER::_Init(@_));
 }
@@ -91,7 +91,7 @@ sub _Init {
 sub Limit  {
   my $self = shift;
   my %args = ( ENTRYAGGREGATOR => 'AND',
-	       @_);
+               @_);
   $self->SUPER::Limit(%args);
 }
 
diff --git a/lib/RT/Record.pm b/lib/RT/Record.pm
index 6dfcc3e..09f77cd 100644
--- a/lib/RT/Record.pm
+++ b/lib/RT/Record.pm
@@ -1063,7 +1063,7 @@ sub HasUnresolvedDependencies {
               VALUE => $args{Type}); 
     }
     else {
-	    $deps->IgnoreType;
+        $deps->IgnoreType;
     }
 
     if ($deps->Count > 0) {
@@ -1137,35 +1137,35 @@ sub _AllLinkedTickets {
         LinkType  => undef,
         Direction => undef,
         Type   => undef,
-	_found => {},
-	_top   => 1,
+        _found => {},
+        _top   => 1,
         @_
     );
 
     my $dep = $self->_Links( $args{Direction}, $args{LinkType});
     while (my $link = $dep->Next()) {
         my $uri = $args{Direction} eq 'Target' ? $link->BaseURI : $link->TargetURI;
-	next unless ($uri->IsLocal());
+        next unless ($uri->IsLocal());
         my $obj = $args{Direction} eq 'Target' ? $link->BaseObj : $link->TargetObj;
-	next if $args{_found}{$obj->Id};
+        next if $args{_found}{$obj->Id};
 
-	if (!$args{Type}) {
-	    $args{_found}{$obj->Id} = $obj;
-	    $obj->_AllLinkedTickets( %args, _top => 0 );
-	}
-	elsif ($obj->Type and $obj->Type eq $args{Type}) {
-	    $args{_found}{$obj->Id} = $obj;
-	}
-	else {
-	    $obj->_AllLinkedTickets( %args, _top => 0 );
-	}
+        if (!$args{Type}) {
+            $args{_found}{$obj->Id} = $obj;
+            $obj->_AllLinkedTickets( %args, _top => 0 );
+        }
+        elsif ($obj->Type and $obj->Type eq $args{Type}) {
+            $args{_found}{$obj->Id} = $obj;
+        }
+        else {
+            $obj->_AllLinkedTickets( %args, _top => 0 );
+        }
     }
 
     if ($args{_top}) {
-	return map { $args{_found}{$_} } sort keys %{$args{_found}};
+        return map { $args{_found}{$_} } sort keys %{$args{_found}};
     }
     else {
-	return 1;
+        return 1;
     }
 }
 
@@ -1233,8 +1233,8 @@ Takes a Type and returns a string that is more human readable.
 sub FormatType{
     my $self = shift;
     my %args = ( Type => '',
-		 @_
-	       );
+                 @_
+               );
     $args{Type} =~ s/([A-Z])/" " . lc $1/ge;
     $args{Type} =~ s/^\s+//;
     return $args{Type};
@@ -1252,12 +1252,12 @@ Takes either a Target or a Base and returns a string of human friendly text.
 sub FormatLink {
     my $self = shift;
     my %args = ( Object => undef,
-		 FallBack => '',
-		 @_
-	       );
+                 FallBack => '',
+                 @_
+               );
     my $text = "URI " . $args{FallBack};
     if ($args{Object} && $args{Object}->isa("RT::Ticket")) {
-	$text = "Ticket " . $args{Object}->id;
+        $text = "Ticket " . $args{Object}->id;
     }
     return $text;
 }
@@ -1544,20 +1544,20 @@ sub _NewTransaction {
     my $new_ref = $args{'NewReference'};
     my $ref_type = $args{'ReferenceType'};
     if ($old_ref or $new_ref) {
-	$ref_type ||= ref($old_ref) || ref($new_ref);
-	if (!$ref_type) {
-	    $RT::Logger->error("Reference type not specified for transaction");
-	    return;
-	}
-	$old_ref = $old_ref->Id if ref($old_ref);
-	$new_ref = $new_ref->Id if ref($new_ref);
+        $ref_type ||= ref($old_ref) || ref($new_ref);
+        if (!$ref_type) {
+            $RT::Logger->error("Reference type not specified for transaction");
+            return;
+        }
+        $old_ref = $old_ref->Id if ref($old_ref);
+        $new_ref = $new_ref->Id if ref($new_ref);
     }
 
     require RT::Transaction;
     my $trans = RT::Transaction->new( $self->CurrentUser );
     my ( $transaction, $msg ) = $trans->Create(
-	ObjectId  => $self->Id,
-	ObjectType => ref($self),
+        ObjectId  => $self->Id,
+        ObjectType => ref($self),
         TimeTaken => $args{'TimeTaken'},
         Type      => $args{'Type'},
         Data      => $args{'Data'},
@@ -1584,7 +1584,7 @@ sub _NewTransaction {
         $self->_UpdateTimeTaken( $args{'TimeTaken'} );
     }
     if ( RT->Config->Get('UseTransactionBatch') and $transaction ) {
-	    push @{$self->{_TransactionBatch}}, $trans if $args{'CommitScrips'};
+            push @{$self->{_TransactionBatch}}, $trans if $args{'CommitScrips'};
     }
 
     RT->DatabaseHandle->Commit unless $in_txn;
@@ -1770,8 +1770,8 @@ sub CustomFieldLookupId {
     # Save a ->Load call by not calling ->FooObj->Id, just ->Foo
     my $final = shift @classes;
     foreach my $class (reverse @classes) {
-	my $method = "${class}Obj";
-	$object = $object->$method;
+        my $method = "${class}Obj";
+        $object = $object->$method;
     }
 
     return $object->$final;
diff --git a/lib/RT/Scrip.pm b/lib/RT/Scrip.pm
index 84a4fe4..cac34cf 100644
--- a/lib/RT/Scrip.pm
+++ b/lib/RT/Scrip.pm
@@ -484,46 +484,46 @@ sub IsApplicable {
     my $return;
     eval {
 
-	my @Transactions;
+        my @Transactions;
 
         my $stage = $self->Stage( TicketObj => $args{'TicketObj'} );
         unless ( $stage ) {
-	    $RT::Logger->error(
+            $RT::Logger->error(
                 "Scrip #". $self->id ." is not applied to"
                 ." queue #". $args{'TicketObj'}->Queue
             );
-	    return (undef);
+            return (undef);
         }
         elsif ( $stage eq 'TransactionCreate') {
-	    # Only look at our current Transaction
-	    @Transactions = ( $args{'TransactionObj'} );
+            # Only look at our current Transaction
+            @Transactions = ( $args{'TransactionObj'} );
         }
         elsif ( $stage eq 'TransactionBatch') {
-	    # Look at all Transactions in this Batch
+            # Look at all Transactions in this Batch
             @Transactions = @{ $args{'TicketObj'}->TransactionBatch || [] };
         }
-	else {
-	    $RT::Logger->error( "Unknown Scrip stage: '$stage'" );
-	    return (undef);
-	}
-	my $ConditionObj = $self->ConditionObj;
-	foreach my $TransactionObj ( @Transactions ) {
-	    # in TxnBatch stage we can select scrips that are not applicable to all txns
-	    my $txn_type = $TransactionObj->Type;
-	    next unless( $ConditionObj->ApplicableTransTypes =~ /(?:^|,)(?:Any|\Q$txn_type\E)(?:,|$)/i );
-	    # Load the scrip's Condition object
-	    $ConditionObj->LoadCondition(
-		ScripObj       => $self,
-		TicketObj      => $args{'TicketObj'},
-		TransactionObj => $TransactionObj,
-	    );
+        else {
+            $RT::Logger->error( "Unknown Scrip stage: '$stage'" );
+            return (undef);
+        }
+        my $ConditionObj = $self->ConditionObj;
+        foreach my $TransactionObj ( @Transactions ) {
+            # in TxnBatch stage we can select scrips that are not applicable to all txns
+            my $txn_type = $TransactionObj->Type;
+            next unless( $ConditionObj->ApplicableTransTypes =~ /(?:^|,)(?:Any|\Q$txn_type\E)(?:,|$)/i );
+            # Load the scrip's Condition object
+            $ConditionObj->LoadCondition(
+                ScripObj       => $self,
+                TicketObj      => $args{'TicketObj'},
+                TransactionObj => $TransactionObj,
+            );
 
             if ( $ConditionObj->IsApplicable() ) {
-	        # We found an application Transaction -- return it
+                # We found an application Transaction -- return it
                 $return = $TransactionObj;
                 last;
             }
-	}
+        }
     };
 
     if ($@) {
@@ -870,10 +870,10 @@ Returns the ScripCondition Object which has the id returned by ScripCondition
 =cut
 
 sub ScripConditionObj {
-	my $self = shift;
-	my $ScripCondition =  RT::ScripCondition->new($self->CurrentUser);
-	$ScripCondition->Load($self->__Value('ScripCondition'));
-	return($ScripCondition);
+        my $self = shift;
+        my $ScripCondition =  RT::ScripCondition->new($self->CurrentUser);
+        $ScripCondition->Load($self->__Value('ScripCondition'));
+        return($ScripCondition);
 }
 
 =head2 ScripAction
@@ -902,10 +902,10 @@ Returns the ScripAction Object which has the id returned by ScripAction
 =cut
 
 sub ScripActionObj {
-	my $self = shift;
-	my $ScripAction =  RT::ScripAction->new($self->CurrentUser);
-	$ScripAction->Load($self->__Value('ScripAction'));
-	return($ScripAction);
+        my $self = shift;
+        my $ScripAction =  RT::ScripAction->new($self->CurrentUser);
+        $ScripAction->Load($self->__Value('ScripAction'));
+        return($ScripAction);
 }
 
 =head2 ConditionRules
@@ -1075,35 +1075,35 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Description =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         ScripCondition =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         ScripAction =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         ConditionRules =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
         ActionRules =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
         CustomIsApplicableCode =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
         CustomPrepareCode =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
         CustomCommitCode =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
         Disabled =>
                 {read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
         Template =>
-		{read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => 'Blank'},
+                {read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => 'Blank'},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/ScripActions.pm b/lib/RT/ScripActions.pm
index 322f7fc..38c8c6d 100644
--- a/lib/RT/ScripActions.pm
+++ b/lib/RT/ScripActions.pm
@@ -84,17 +84,17 @@ sub LimitToType  {
   my $self = shift;
   my $type = shift;
   $self->Limit (ENTRYAGGREGATOR => 'OR',
-		FIELD => 'Type',
-		VALUE => "$type")
+                FIELD => 'Type',
+                VALUE => "$type")
       if defined $type;
   $self->Limit (ENTRYAGGREGATOR => 'OR',
-		FIELD => 'Type',
-		VALUE => "Correspond")
+                FIELD => 'Type',
+                VALUE => "Correspond")
       if $type eq "Create";
   $self->Limit (ENTRYAGGREGATOR => 'OR',
-		FIELD => 'Type',
-		VALUE => 'any');
-  
+                FIELD => 'Type',
+                VALUE => 'any');
+
 }
 
 =head2 NewItem
diff --git a/lib/RT/ScripCondition.pm b/lib/RT/ScripCondition.pm
index ece67a4..dd15cc9 100644
--- a/lib/RT/ScripCondition.pm
+++ b/lib/RT/ScripCondition.pm
@@ -81,15 +81,15 @@ sub Table {'ScripConditions'}
 sub _Accessible  {
     my $self = shift;
     my %Cols = ( Name  => 'read',
-		 Description => 'read',
-		 ApplicableTransTypes	 => 'read',
-		 ExecModule  => 'read',
-		 Argument  => 'read',
-		 Creator => 'read/auto',
-		 Created => 'read/auto',
-		 LastUpdatedBy => 'read/auto',
-		 LastUpdated => 'read/auto'
-	       );
+                 Description => 'read',
+                 ApplicableTransTypes => 'read',
+                 ExecModule  => 'read',
+                 Argument  => 'read',
+                 Creator => 'read/auto',
+                 Created => 'read/auto',
+                 LastUpdatedBy => 'read/auto',
+                 LastUpdated => 'read/auto'
+               );
     return($self->SUPER::_Accessible(@_, %Cols));
 }
 
@@ -128,16 +128,16 @@ Loads a condition takes a name or ScripCondition id.
 sub Load  {
     my $self = shift;
     my $identifier = shift;
-    
+
     unless (defined $identifier) {
-	return (undef);
-    }	    
-    
+        return (undef);
+    }
+
     if ($identifier !~ /\D/) {
-	return ($self->SUPER::LoadById($identifier));
+        return ($self->SUPER::LoadById($identifier));
     }
     else {
-	return ($self->LoadByCol('Name', $identifier));
+        return ($self->LoadByCol('Name', $identifier));
     }
 }
 
@@ -153,24 +153,24 @@ Loads the Condition module in question.
 sub LoadCondition  {
     my $self = shift;
     my %args = ( TransactionObj => undef,
-		 TicketObj => undef,
-		 @_ );
-    
-    #TODO: Put this in an eval  
+                 TicketObj => undef,
+                 @_ );
+
+    #TODO: Put this in an eval
     $self->ExecModule =~ /^(\w+)$/;
     my $module = $1;
     my $type = "RT::Condition::". $module;
-    
+
     eval "require $type" || die "Require of $type failed.\n$@\n";
-    
-    $self->{'Condition'}  = $type->new ( 'ScripConditionObj' => $self, 
-					 'TicketObj' => $args{'TicketObj'},
-					 'ScripObj' => $args{'ScripObj'},
-					 'TransactionObj' => $args{'TransactionObj'},
-					 'Argument' => $self->Argument,
-				     'ApplicableTransTypes' => $self->ApplicableTransTypes,
-                     CurrentUser => $self->CurrentUser 
-				       );
+
+    $self->{'Condition'}  = $type->new ( 'ScripConditionObj' => $self,
+                                         'TicketObj' => $args{'TicketObj'},
+                                         'ScripObj' => $args{'ScripObj'},
+                                         'TransactionObj' => $args{'TransactionObj'},
+                                         'Argument' => $self->Argument,
+                                         'ApplicableTransTypes' => $self->ApplicableTransTypes,
+                                         CurrentUser => $self->CurrentUser
+                                       );
 }
 
 
@@ -343,25 +343,25 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Name =>
-		{read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => ''},
         Description =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         ExecModule =>
-		{read => 1, write => 1, sql_type => 12, length => 60,  is_blob => 0,  is_numeric => 0,  type => 'varchar(60)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 60,  is_blob => 0,  is_numeric => 0,  type => 'varchar(60)', default => ''},
         Argument =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varbinary(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varbinary(255)', default => ''},
         ApplicableTransTypes =>
-		{read => 1, write => 1, sql_type => 12, length => 60,  is_blob => 0,  is_numeric => 0,  type => 'varchar(60)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 60,  is_blob => 0,  is_numeric => 0,  type => 'varchar(60)', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/ScripConditions.pm b/lib/RT/ScripConditions.pm
index a247a33..b0d9e6f 100644
--- a/lib/RT/ScripConditions.pm
+++ b/lib/RT/ScripConditions.pm
@@ -80,17 +80,17 @@ sub LimitToType  {
   my $self = shift;
   my $type = shift;
   $self->Limit (ENTRYAGGREGATOR => 'OR',
-		FIELD => 'Type',
-		VALUE => "$type")
+                FIELD => 'Type',
+                VALUE => "$type")
       if defined $type;
   $self->Limit (ENTRYAGGREGATOR => 'OR',
-		FIELD => 'Type',
-		VALUE => "Correspond")
+                FIELD => 'Type',
+                VALUE => "Correspond")
       if $type eq "Create";
   $self->Limit (ENTRYAGGREGATOR => 'OR',
-		FIELD => 'Type',
-		VALUE => 'any');
-  
+                FIELD => 'Type',
+                VALUE => 'any');
+
 }
 
 
diff --git a/lib/RT/Scrips.pm b/lib/RT/Scrips.pm
index aa0e59b..c020ae0 100644
--- a/lib/RT/Scrips.pm
+++ b/lib/RT/Scrips.pm
@@ -245,28 +245,28 @@ sub ApplySortOrder {
 Returns the next scrip that this user can see.
 
 =cut
-  
+
 sub Next {
     my $self = shift;
-    
-    
+
+
     my $Scrip = $self->SUPER::Next();
     if ((defined($Scrip)) and (ref($Scrip))) {
 
-	if ($Scrip->CurrentUserHasRight('ShowScrips')) {
-	    return($Scrip);
-	}
-	
-	#If the user doesn't have the right to show this scrip
-	else {	
-	    return($self->Next());
-	}
+        if ($Scrip->CurrentUserHasRight('ShowScrips')) {
+            return($Scrip);
+        }
+
+        #If the user doesn't have the right to show this scrip
+        else {
+            return($self->Next());
+        }
     }
     #if there never was any scrip
     else {
-	return(undef);
-    }	
-    
+        return(undef);
+    }
+
 }
 
 =head2 Apply
@@ -470,13 +470,13 @@ sub _FindScrips {
     #We only want things where the scrip applies to this sort of transaction
     # TransactionBatch stage can define list of transaction
     foreach( split /\s*,\s*/, ($args{'Type'} || '') ) {
-	$self->Limit(
-	    ALIAS           => $ConditionsAlias,
-	    FIELD           => 'ApplicableTransTypes',
-	    OPERATOR        => 'LIKE',
-	    VALUE           => $_,
-	    ENTRYAGGREGATOR => 'OR',
-	)
+        $self->Limit(
+            ALIAS           => $ConditionsAlias,
+            FIELD           => 'ApplicableTransTypes',
+            OPERATOR        => 'LIKE',
+            VALUE           => $_,
+            ENTRYAGGREGATOR => 'OR',
+        )
     }
 
     # Or where the scrip applies to any transaction
diff --git a/lib/RT/SearchBuilder.pm b/lib/RT/SearchBuilder.pm
index 115e37b..cfdb3c5 100644
--- a/lib/RT/SearchBuilder.pm
+++ b/lib/RT/SearchBuilder.pm
@@ -77,10 +77,10 @@ sub _Init  {
     
     $self->{'user'} = shift;
     unless(defined($self->CurrentUser)) {
-	use Carp;
-	Carp::confess("$self was created without a CurrentUser");
-	$RT::Logger->err("$self was created without a CurrentUser");
-	return(0);
+        use Carp;
+        Carp::confess("$self was created without a CurrentUser");
+        $RT::Logger->err("$self was created without a CurrentUser");
+        return(0);
     }
     $self->SUPER::_Init( 'Handle' => $RT::Handle);
 }
diff --git a/lib/RT/SharedSetting.pm b/lib/RT/SharedSetting.pm
index 8bff4c0..c54b350 100644
--- a/lib/RT/SharedSetting.pm
+++ b/lib/RT/SharedSetting.pm
@@ -192,7 +192,7 @@ sub Save {
     my %args = (
         'Privacy' => 'RT::User-' . $self->CurrentUser->Id,
         'Name'    => "new " . $self->ObjectName,
-		@_,
+        @_,
     );
 
     my $privacy = $args{'Privacy'};
diff --git a/lib/RT/StyleGuide.pod b/lib/RT/StyleGuide.pod
index d958c87..deeb09f 100644
--- a/lib/RT/StyleGuide.pod
+++ b/lib/RT/StyleGuide.pod
@@ -26,7 +26,7 @@ want to make up for it now.
 
 If you have any questions, please ask us on the B<rt-devel> mailing list:
 
-	http://www.bestpractical.com/rt/lists.html
+        http://www.bestpractical.com/rt/lists.html
 
 We don't always follow this guide.  We are making changes throughout
 our code to be in line with it.  But just because we didn't do
@@ -71,7 +71,7 @@ purpose, and use in a mason comment block.
 
 Any external documents, and documentation for command-line programs and
 modules, should be written in POD, where appropriate. From there, they
-can be translated to many formats with the various pod2* translators. 
+can be translated to many formats with the various pod2* translators.
 Read the perlpod manpage before writing any POD, because although POD is
 not difficult, it is not what most people are used to.  It is not a
 regular markup language; it is just a way to make easy documentation
@@ -86,24 +86,24 @@ major revision, the second number is the version, and third
 number is the subversion.  Odd-numbered versions are development
 versions.  Examples:
 
-	1.0.0		First release of RT 1
-	1.0.1		Second release of RT 1.0
-	1.0.10		etc.
-	1.1.0		First development release of RT 1.2 (or 2.0)
-	2.0.0		First release of RT 2
+        1.0.0           First release of RT 1
+        1.0.1           Second release of RT 1.0
+        1.0.10          etc.
+        1.1.0           First development release of RT 1.2 (or 2.0)
+        2.0.0           First release of RT 2
 
 Versions can be modified with a hyphen followed by some text, for
 special versions, or to give extra information.  Examples:
 
-	2.0.0-pre1	Notes that this is not final, but preview
+        2.0.0-pre1      Notes that this is not final, but preview
 
 In perl 5.6.0, you can have versions like C<v2.0.0>, but this is not
 allowed in previous versions of perl.  So to convert a tuple version
 string to a string to use with $VERSION, use a regular integer for
 the revision, and three digits for version and subversion.  Examples:
 
-	1.1.6	->	1.001006
-	2.0.0	->	2.000000
+        1.1.6   ->      1.001006
+        2.0.0   ->      2.000000
 
 This way, perl can use the version strings in greater-than and
 less-than comparisons.
@@ -115,8 +115,8 @@ All code should be self-documenting as much as possible.  Only include
 necessary comments.  Use names like "$ticket_count", so you don't need to
 do something like:
 
-	# ticket count
-	my $tc = 0;
+        # ticket count
+        my $tc = 0;
 
 Include any comments that are, or might be, necessary in order for
 someone else to understand the code.  Sometimes a simple one-line
@@ -166,21 +166,21 @@ Arrays and hashes should be passed to and from functions by reference
 only.  Note that a list and an array are NOT the same thing.  This
 is perfectly fine:
 
-	return($user, $form, $constants);
+        return($user, $form, $constants);
 
 An exception might be a temporary array of discrete arguments:
 
-	my @return = ($user, $form);
-	push @return, $constants if $flag;
-	return @return;
+        my @return = ($user, $form);
+        push @return, $constants if $flag;
+        return @return;
 
 Although, usually, this is better (faster, easier to read, etc.):
 
-	if ($flag) {
-		return($user, $form, $constants);
-	} else {
-		return($user, $form);
-	}
+        if ($flag) {
+                return($user, $form, $constants);
+        } else {
+                return($user, $form);
+        }
 
 We need to talk about Class::ReturnValue here.
 
@@ -201,16 +201,16 @@ Also, if you have a long-running function that has a large data
 structure in it, it is polite to free up the memory as soon as you are
 done with it, if possible.
 
-	my $huge_data_structure = get_huge_data_structure();
-	do_something_with($huge_data_structure);
-	undef $huge_data_structure;
+        my $huge_data_structure = get_huge_data_structure();
+        do_something_with($huge_data_structure);
+        undef $huge_data_structure;
 
 =head2 DESTROY
 
 All object classes must provide a DESTROY method.  If it won't do
 anything, provide it anyway:
 
-	sub DESTROY { }
+        sub DESTROY { }
 
 
 
@@ -224,18 +224,18 @@ In command-line programs, do as you please.
 
 =head2 shift and @_
 
-Do not use @_.  Use shift.  shift may take more lines, but Jesse thinks it 
+Do not use @_.  Use shift.  shift may take more lines, but Jesse thinks it
 leads to cleaner code.
 
-	my $var = shift;			# right
-	my($var) = @_;				# ick. no
-	sub foo { uc $_[0] }			# icky. sometimes ok.
+        my $var = shift;                        # right
+        my($var) = @_;                          # ick. no
+        sub foo { uc $_[0] }                    # icky. sometimes ok.
 
 
-	my($var1, $var2) = (shift, shift);	# Um, no.
+        my($var1, $var2) = (shift, shift);      # Um, no.
 
         my $var1 = shift;                       # right
-        my $var2 = shift;                       
+        my $var2 = shift;
 
 =head2 Method parameters
 
@@ -314,7 +314,7 @@ use the logging API.
 =head2 System Calls
 
 Always check return values from system calls, including open(),
-close(), mkdir(), or anything else that talks directly to the system. 
+close(), mkdir(), or anything else that talks directly to the system.
 Perl built-in system calls return the error in $!; some functions in
 modules might return an error in $@ or some other way, so read the module's
 documentation if you don't know.  Always do something, even if it is
@@ -335,7 +335,7 @@ document, too.
 =item RT the name
 
 "RT" is the name of the project.  "RT" is, optionally, the
-specific name for the actual file distribution.  That's it. 
+specific name for the actual file distribution.  That's it.
 
 While we sometimes use "RT2" or "RT3", that's shortand that's really
 not recommended. The name of the project is "RT".
@@ -357,7 +357,7 @@ are optionally called constructors.
 =item Users
 
 "users" are normally users of RT, the ones hitting the site; if using
-it in any other context, specify.  
+it in any other context, specify.
 "system users" are user
 names on the operating system.  "database users" are the user names in
 the database server.  None of these needs to be capitalized.
@@ -374,28 +374,28 @@ Don't use two-character variables just to spite us over the above rule.
 Constants are in all caps; these are variables whose value will I<never>
 change during the course of the program.
 
-	$Minimum = 10;		# wrong
-	$MAXIMUM = 50;		# right
+        $Minimum = 10;          # wrong
+        $MAXIMUM = 50;          # right
 
-Other variables are lowercase, with underscores separating the words. 
+Other variables are lowercase, with underscores separating the words.
 They words used should, in general, form a noun (usually singular),
 unless the variable is a flag used to denote some action that should be
 taken, in which case they should be verbs (or gerunds, as appropriate)
 describing that action.
 
-	$thisVar      = 'foo';	# wrong
-	$this_var     = 'foo';	# right
-	$work_hard    = 1;	# right, verb, boolean flag
-	$running_fast = 0;	# right, gerund, boolean flag
+        $thisVar      = 'foo';  # wrong
+        $this_var     = 'foo';  # right
+        $work_hard    = 1;      # right, verb, boolean flag
+        $running_fast = 0;      # right, gerund, boolean flag
 
 Arrays and hashes should be plural nouns, whether as regular arrays and
 hashes or array and hash references.  Do not name references with "ref"
 or the data type in the name.
 
-	@stories     = (1, 2, 3);      # right
-	$comment_ref = [4, 5, 6];      # wrong
-	$comments    = [4, 5, 6];      # right
-	$comment     = $comments->[0]; # right
+        @stories     = (1, 2, 3);      # right
+        $comment_ref = [4, 5, 6];      # wrong
+        $comments    = [4, 5, 6];      # right
+        $comment     = $comments->[0]; # right
 
 Make the name descriptive.  Don't use variables like "$sc" when you
 could call it "$story_count".  See L<"Comments">.
@@ -405,7 +405,7 @@ that you should use in your code.  Do not use these variable names for
 anything other than how they are normally used, and do not use any
 other variable names in their place.  Some of these are:
 
-	$self		# first named argument in object method
+        $self           # first named argument in object method
 
 Subroutines (except for special cases, like AUTOLOAD and simple accessors)
 begin with a verb, with words following to complete the action.  Accessors
@@ -417,13 +417,13 @@ This section needs clarification for RT.
 
 Words begin with a capital letter.  They
 should as clearly as possible describe the activity to be peformed, and
-the data to be returned. 
+the data to be returned.
 
 
 
-	Load();		# good
-	LoadByName();	# good
-	LoadById();		# good
+        Load();         # good
+        LoadByName();   # good
+        LoadById();             # good
 
 Subroutines beginning with C<_> are special: they are not to be used
 outside the current object.  There is not to be enforced by the code
@@ -434,11 +434,11 @@ Do not use $_ (or assume it) except for when it is absolutely
 clear what is going on, or when it is required (such as with
 map() and grep()).
 
-	for (@list) {
-		print;			# OK; everyone knows this one
-		print uc;		# wrong; few people know this
-		print uc $_;		# better
-	}
+        for (@list) {
+                print;                  # OK; everyone knows this one
+                print uc;               # wrong; few people know this
+                print uc $_;            # better
+        }
 
 Note that the special variable C<_> I<should> be used when possible.
 It is a placeholder that can be passed to stat() and the file test
@@ -447,29 +447,29 @@ example below, using C<$file> over for each file test, instead of
 C<_> for subsequent uses, is a performance hit.  You should be
 careful that the last-tested file is what you think it is, though.
 
-	if (-d $file) {		# $file is a directory
-		# ...
-	} elsif (-l _) {	# $file is a symlink
-		# ...
-	}
+        if (-d $file) {         # $file is a directory
+                # ...
+        } elsif (-l _) {        # $file is a symlink
+                # ...
+        }
 
 Package names begin with a capital letter in each word, followed by
 lower case letters (for the most part).  Multiple words should be StudlyCapped.
 
-	RT::User			# good
-	RT::Database::MySQL		# proper name
-	RT::Display::Provider	        # good
-	RT::CustomField			# not so good, but OK
+        RT::User                        # good
+        RT::Database::MySQL             # proper name
+        RT::Display::Provider           # good
+        RT::CustomField                 # not so good, but OK
 
 Plugin modules should begin with "RTx::", followed by the name
-of the plugin.  
+of the plugin.
 
 =head1 Code formatting
 
 Use perltidy. Anything we say here is wrong if it conflicts with what
 perltidy does. Your perltidyrc should read:
 
--lp -vt=2 -vtc=2 -nsfs -bar                                                                                             
+-lp -vt=2 -vtc=2 -nsfs -bar
 
 =head2 Indents and Blank Space
 
@@ -478,25 +478,25 @@ to be; I use 8 spaces per tabs.
 
 No space before a semicolon that closes a statement.
 
-	foo(@bar) ;	# wrong
-	foo(@bar);	# right
+        foo(@bar) ;     # wrong
+        foo(@bar);      # right
 
 Line up corresponding items vertically.
 
-	my $foo   = 1;
-	my $bar   = 2;
-	my $xyzzy = 3;
+        my $foo   = 1;
+        my $bar   = 2;
+        my $xyzzy = 3;
 
-	open(FILE, $fh)	  or die $!;
-	open(FILE2, $fh2) or die $!;
+        open(FILE, $fh)   or die $!;
+        open(FILE2, $fh2) or die $!;
 
-	$rot13 =~ tr[abcedfghijklmnopqrstuvwxyz]
-	            [nopqrstuvwxyzabcdefghijklm];
+        $rot13 =~ tr[abcedfghijklmnopqrstuvwxyz]
+                    [nopqrstuvwxyzabcdefghijklm];
 
-	# note we use a-mn-z instead of a-z,
-	# for readability
-	$rot13 =~ tr[a-mn-z]
-	            [n-za-m];
+        # note we use a-mn-z instead of a-z,
+        # for readability
+        $rot13 =~ tr[a-mn-z]
+                    [n-za-m];
 
 Put blank lines between groups of code that do different things.  Put
 blank lines after your variable declarations.  Put a blank line before a
@@ -505,20 +505,20 @@ before, with the exception of comment lines).
 
 An example:
 
-	# this is my function!
-	sub foo {
+        # this is my function!
+        sub foo {
                 my $val = shift;
-		my $obj = new Constructor;
-		my($var1, $var2);
+                my $obj = new Constructor;
+                my($var1, $var2);
 
-		$obj->SetFoo($val);
-		$var1 = $obj->Foo();
+                $obj->SetFoo($val);
+                $var1 = $obj->Foo();
 
 
-		return($val);
-	}
+                return($val);
+        }
 
-	print 1;
+        print 1;
 
 
 =head2 Parentheses
@@ -526,19 +526,19 @@ An example:
 For control structures, there is a space between the keyword and opening
 parenthesis.  For functions, there is not.
 
-	for(@list)	# wrong
-	for (@list)	# right
+        for(@list)      # wrong
+        for (@list)     # right
 
-	my ($ref)	# wrong
-	my($ref)	# right
+        my ($ref)       # wrong
+        my($ref)        # right
 
 Be careful about list vs. scalar context with parentheses!
 
-	my @array = ('a', 'b', 'c');
-	my($first_element) = @array;		# a
-	my($first_element) = ('a', 'b', 'c');	# a
-	my $element_count  = @array;		# 3
-	my $last_element   = ('a', 'b', 'c');	# c
+        my @array = ('a', 'b', 'c');
+        my($first_element) = @array;            # a
+        my($first_element) = ('a', 'b', 'c');   # a
+        my $element_count  = @array;            # 3
+        my $last_element   = ('a', 'b', 'c');   # c
 
 Always include parentheses after functions, even if there are no arguments.
 There are some exceptions, such as list operators (like print) and unary
@@ -547,28 +547,28 @@ operators (like undef, delete, uc).
 There is no space inside the parentheses, unless it is needed for
 readability.
 
-	for ( map { [ $_, 1 ] } @list )	# OK
-	for ( @list )			# not really OK, not horrible
+        for ( map { [ $_, 1 ] } @list ) # OK
+        for ( @list )                   # not really OK, not horrible
 
 On multi-line expressions, match up the closing parenthesis with either
 the opening statement, or the opening parenthesis, whichever works best.
 Examples:
 
-	@list = qw(
-		bar
-		baz
-	);			# right
+        @list = qw(
+                bar
+                baz
+        );                      # right
 
-	if ($foo && $bar && $baz
-		 && $buz && $xyzzy
-	) {
-		print $foo;
-	}
+        if ($foo && $bar && $baz
+                 && $buz && $xyzzy
+        ) {
+                print $foo;
+        }
 
 Whether or not there is space following a closing parenthesis is
 dependent on what it is that follows.
 
-	print foo(@bar), baz(@buz) if $xyzzy;
+        print foo(@bar), baz(@buz) if $xyzzy;
 
 Note also that parentheses around single-statement control expressions,
 as in C<if $xyzzy>, are optional (and discouraged) C<if> it is I<absolutely>
@@ -583,19 +583,19 @@ function call in the statement, or the function call is separated by a
 flow control operator).  User-supplied functions must always include
 parentheses.
 
-	print 1, 2, 3;				# good
-	delete $hash{key} if isAnon($uid);	# good
+        print 1, 2, 3;                          # good
+        delete $hash{key} if isAnon($uid);      # good
 
 
 However, if there is any possible confusion at all, then include the
 parentheses.  Remember the words of Larry Wall in the perlstyle manpage:
 
-	When in doubt, parenthesize.  At the very least it will
-	let some poor schmuck bounce on the % key in vi.
+        When in doubt, parenthesize.  At the very least it will
+        let some poor schmuck bounce on the % key in vi.
 
-	Even if you aren't in doubt, consider the mental welfare
-	of the person who has to maintain the code after you, and
-	who will probably put parens in the wrong place.
+        Even if you aren't in doubt, consider the mental welfare
+        of the person who has to maintain the code after you, and
+        who will probably put parens in the wrong place.
 
 So leave them out when it is absoutely clear to a programmer, but if
 there is any question, leave them in.
@@ -607,40 +607,40 @@ there is any question, leave them in.
 
 There is always a space befor the opening brace.
 
-	while (<$fh>){	# wrong
-	while (<$fh>) {	# right
+        while (<$fh>){  # wrong
+        while (<$fh>) { # right
 
 A one-line block may be put on one line, and the semicolon may be
 omitted.
 
-	for (@list) { print }
+        for (@list) { print }
 
 Otherwise, finish each statement with a semicolon, put the keyword and
 opening curly on the first line, and the ending curly lined up with the
 keyword at the end.
 
-	for (@list) {
-		print;
-		smell();
-	}
+        for (@list) {
+                print;
+                smell();
+        }
 
 Generally, we prefer "uncuddled elses":
 
-	if ($foo) {
-		print;
-	}
-	else {
-		die;
-	}
+        if ($foo) {
+                print;
+        }
+        else {
+                die;
+        }
 
 _If_ the if statement is very brief, sometimes "cuddling" the else makes code more readable. Feel free to cuddle them in that case:
 
 
-	if ($foo) {
-		print;
-	} else {
-		die;
-	}
+        if ($foo) {
+                print;
+        } else {
+                die;
+        }
 
 =head2 Operators
 
@@ -648,28 +648,28 @@ Put space around most operators.  The primary exception is the for
 aesthetics; e.g., sometimes the space around "**" is ommitted,
 and there is never a space before a ",", but always after.
 
-	print $x , $y;	# wrong
-	print $x, $y;	# right
+        print $x , $y;  # wrong
+        print $x, $y;   # right
 
-	$x = 2 >> 1;	# good
-	$y = 2**2;	# ok
+        $x = 2 >> 1;    # good
+        $y = 2**2;      # ok
 
-Note that "&&" and "||" have a higher precedence than "and" and "or". 
+Note that "&&" and "||" have a higher precedence than "and" and "or".
 Other than that, they are exactly the same.  It is best to use the lower
 precedence version for control, and the higher for testing/returning
 values.  Examples:
 
-	$bool = $flag1 or $flag2;	# WRONG (doesn't work)
-	$value = $foo || $bar;		# right
-	open(FILE, $file) or die $!;
+        $bool = $flag1 or $flag2;       # WRONG (doesn't work)
+        $value = $foo || $bar;          # right
+        open(FILE, $file) or die $!;
 
-	$true  = foo($bar) && baz($buz);
-	foo($bar) and baz($buz);
+        $true  = foo($bar) && baz($buz);
+        foo($bar) and baz($buz);
 
 Note that "and" is seldom ever used, because the statement above is
 better written using "if":
 
-	baz($buz) if foo($bar);
+        baz($buz) if foo($bar);
 
 Most of the time, the confusion between and/&&, or/|| can be alleviated
 by using parentheses.  If you want to leave off the parentheses then you
@@ -682,51 +682,51 @@ Break long lines AFTER operators, except for "and", "or", "&&", "||".
 Try to keep the two parts to a binary operator (an operator that
 has two operands) together when possible.
 
-	print "foo" . "bar" . "baz"
-		. "buz";			# wrong
+        print "foo" . "bar" . "baz"
+                . "buz";                        # wrong
 
-	print "foo" . "bar" . "baz" .
-		"buz";				# right
+        print "foo" . "bar" . "baz" .
+                "buz";                          # right
 
-	print $foo unless $x == 3 && $y ==
-		4 && $z == 5;			# wrong
+        print $foo unless $x == 3 && $y ==
+                4 && $z == 5;                   # wrong
 
-	print $foo unless $x == 3 && $y == 4
-		&& $z == 5;			# right
+        print $foo unless $x == 3 && $y == 4
+                && $z == 5;                     # right
 
 
 =head2 Other
 
 Put space around a complex subscript inside the brackets or braces.
 
-	$foo{$bar{baz}{buz}};	# OK
-	$foo{ $bar{baz}{buz} };	# better
+        $foo{$bar{baz}{buz}};   # OK
+        $foo{ $bar{baz}{buz} }; # better
 
 In general, use single-quotes around literals, and double-quotes
-when the text needs to be interpolated. 
+when the text needs to be interpolated.
 
 It is OK to omit quotes around names in braces and when using
 the => operator, but be careful not to use a name that doubles as
 a function; in that case, quote.
 
-	$what{'time'}{it}{is} = time();
+        $what{'time'}{it}{is} = time();
 
 When making compound statements, put the primary action first.
 
-	open(FILE, $fh) or die $!;	# right
-	die $! unless open(FILE, $fh);	# wrong
+        open(FILE, $fh) or die $!;      # right
+        die $! unless open(FILE, $fh);  # wrong
 
-	print "Starting\n" if $verbose;	# right
-	$verbose && print "Starting\n";	# wrong
+        print "Starting\n" if $verbose; # right
+        $verbose && print "Starting\n"; # wrong
 
 
 Use here-docs instead of repeated print statements.
 
-		print <<EOT;
-	This is a whole bunch of text.
-	I like it.  I don't need to worry about messing
-	with lots of print statements and lining them up.
-	EOT
+                print <<EOT;
+        This is a whole bunch of text.
+        I like it.  I don't need to worry about messing
+        with lots of print statements and lining them up.
+        EOT
 
 Just remember that unless you put single quotes around your here-doc
 token (<<'EOT'), the text will be interpolated, so escape any "$" or "@"
@@ -744,67 +744,67 @@ as needed.
 Templates should use the /l filtering component to call the localisation
 framework
 
-The string 		Foo!
+The string              Foo!
 
-Should become		<&|/l&>Foo!</&>
+Should become           <&|/l&>Foo!</&>
 
-All newlines should be removed from localized strings, to make it easy to 
+All newlines should be removed from localized strings, to make it easy to
 grep the codebase for strings to be localized
 
-The string 		Foo
-			Bar
-			Baz
-			
-Should become		<&|/l&>Foo Bar Baz</&>
+The string              Foo
+                        Bar
+                        Baz
+
+Should become           <&|/l&>Foo Bar Baz</&>
 
 
 Variable subsititutions should be moved to Locale::MakeText format
 
-The string		Hello, <%$name %>
+The string              Hello, <%$name %>
 
-should become		<&|/l, $name &>Hello, [_1]</&>	
+should become           <&|/l, $name &>Hello, [_1]</&>
 
 
 Multiple variables work just like single variables
- 
-The string		You found <%$num%> tickets in queue <%$queue%>
 
-should become		<&|/l, $num, $queue &>You found [_1] tickets in queue [_2]</&>
+The string              You found <%$num%> tickets in queue <%$queue%>
+
+should become           <&|/l, $num, $queue &>You found [_1] tickets in queue [_2]</&>
 
 When subcomponents are called in the middle of a phrase, they need to be escaped
 too:
 
-The string		 <input type="submit" value="New ticket in">&nbsp<& /Elements/SelectNewTicketQueue&>
+The string               <input type="submit" value="New ticket in">&nbsp<& /Elements/SelectNewTicketQueue&>
 
-should become		<&|/l, $m->scomp('/Elements/SelectNewTicketQueue')&><input type="submit" value="New ticket in"> [_1]</&>
+should become           <&|/l, $m->scomp('/Elements/SelectNewTicketQueue')&><input type="submit" value="New ticket in"> [_1]</&>
 
 
 
 
-The string	<& /Elements/TitleBoxStart, width=> "40%", titleright => "RT $RT::VERSION for   RT->Config->Get('rtname')", title => 'Login' &>
+The string      <& /Elements/TitleBoxStart, width=> "40%", titleright => "RT $RT::VERSION for   RT->Config->Get('rtname')", title => 'Login' &>
 
-should become 	<& /Elements/TitleBoxStart, 
-			width=> "40%",
-			titleright => loc("RT [_1] for [_2]",$RT::VERSION, RT->Config->Get('rtname')),
-			title => loc('Login'),
-	      	&>
-	
+should become   <& /Elements/TitleBoxStart,
+                        width=> "40%",
+                        titleright => loc("RT [_1] for [_2]",$RT::VERSION, RT->Config->Get('rtname')),
+                        title => loc('Login'),
+                &>
 
-=item Library code			
+
+=item Library code
 
 
 
 Within RT's core code, every module has a localization handle available through the 'loc' method:
 
-The code 	return ( $id, "Queue created" );
+The code        return ( $id, "Queue created" );
 
-should become 	return ( $id, $self->loc("Queue created") );	
+should become   return ( $id, $self->loc("Queue created") );
 
 When returning or localizing a single string, the "extra" set of parenthesis () should be omitted.
 
-The code  	return ("Subject changed to ". $self->Data );
+The code        return ("Subject changed to ". $self->Data );
 
-should become	 return $self->loc( "Subject changed to [_1]", $self->Data );
+should become    return $self->loc( "Subject changed to [_1]", $self->Data );
 
 
 It is important not to localize  the names of rights or statuses within RT's core, as there is logic that depends on them as string identifiers.  The proper place to localize these values is when they're presented for display in the web or commandline interfaces.
@@ -821,7 +821,7 @@ This is for new programs, modules, specific APIs, or anything else.
 =item Present idea to rt-devel
 
 We may know of a better way to approach the problem, or know of an
-existing way to deal with it, or know someone else is working on it. 
+existing way to deal with it, or know someone else is working on it.
 This is mostly informal, but a fairly complete explanation for the need
 and use of the code should be provided.
 
@@ -915,7 +915,7 @@ Talk about DBIx::SearchBuilder
 Talk about mason
         component style
         cascading style sheets
-         
+
 Talk about adding a new translation
 
 Talk more about logging
@@ -927,4 +927,4 @@ Talk more about logging
 
 =head1 VERSION
 
-0.1 
+0.1
diff --git a/lib/RT/Template.pm b/lib/RT/Template.pm
index 8a8e594..21022f5 100644
--- a/lib/RT/Template.pm
+++ b/lib/RT/Template.pm
@@ -869,10 +869,10 @@ Returns the Queue Object which has the id returned by Queue
 =cut
 
 sub QueueObj {
-	my $self = shift;
-	my $Queue =  RT::Queue->new($self->CurrentUser);
-	$Queue->Load($self->__Value('Queue'));
-	return($Queue);
+    my $self = shift;
+    my $Queue =  RT::Queue->new($self->CurrentUser);
+    $Queue->Load($self->__Value('Queue'));
+    return($Queue);
 }
 
 =head2 Name
@@ -1024,29 +1024,29 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Queue =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Name =>
-		{read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => ''},
         Description =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         Type =>
-		{read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
         Language =>
-		{read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
         TranslationOf =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Content =>
-		{read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
+                {read => 1, write => 1, sql_type => -4, length => 0,  is_blob => 1,  is_numeric => 0,  type => 'text', default => ''},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Templates.pm b/lib/RT/Templates.pm
index 053c9a3..dd1bddf 100644
--- a/lib/RT/Templates.pm
+++ b/lib/RT/Templates.pm
@@ -130,32 +130,32 @@ sub LimitToQueue {
 Returns the next template that this user can see.
 
 =cut
-  
+
 sub Next {
     my $self = shift;
-    
-    
+
+
     my $templ = $self->SUPER::Next();
     if ((defined($templ)) and (ref($templ))) {
-        
+
         # If it's part of a queue, and the user can read templates in
         # that queue, or the user can globally read templates, show it
         if ($templ->Queue && $templ->CurrentUserHasQueueRight('ShowTemplate') or
             $templ->CurrentUser->HasRight(Object => $RT::System, Right => 'ShowTemplate') or
             $templ->CurrentUser->HasRight(Object => $RT::System, Right => 'ShowGlobalTemplates')) {
-	    return($templ);
-	}
-	
-	#If the user doesn't have the right to show this template
-	else {	
-	    return($self->Next());
-	}
+            return($templ);
+        }
+
+        #If the user doesn't have the right to show this template
+        else {
+            return($self->Next());
+        }
     }
     #if there never was any template
     else {
-	return(undef);
-    }	
-    
+        return(undef);
+    }
+
 }
 
 =head2 NewItem
diff --git a/lib/RT/Ticket.pm b/lib/RT/Ticket.pm
index b2a3127..ca0bb5f 100644
--- a/lib/RT/Ticket.pm
+++ b/lib/RT/Ticket.pm
@@ -3493,55 +3493,55 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         EffectiveId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Queue =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Type =>
-		{read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 16,  is_blob => 0,  is_numeric => 0,  type => 'varchar(16)', default => ''},
         IssueStatement =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Resolution =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Owner =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Subject =>
-		{read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => '[no subject]'},
+                {read => 1, write => 1, sql_type => 12, length => 200,  is_blob => 0,  is_numeric => 0,  type => 'varchar(200)', default => '[no subject]'},
         InitialPriority =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         FinalPriority =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Priority =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         TimeEstimated =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         TimeWorked =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Status =>
-		{read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
         TimeLeft =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Told =>
-		{read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Starts =>
-		{read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Started =>
-		{read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Due =>
-		{read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Resolved =>
-		{read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, write => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         LastUpdatedBy =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         LastUpdated =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
         Disabled =>
-		{read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
+                {read => 1, write => 1, sql_type => 5, length => 6,  is_blob => 0,  is_numeric => 1,  type => 'smallint(6)', default => '0'},
 
  }
 };
diff --git a/lib/RT/Tickets.pm b/lib/RT/Tickets.pm
index fc3a7f1..f958681 100644
--- a/lib/RT/Tickets.pm
+++ b/lib/RT/Tickets.pm
@@ -1169,11 +1169,11 @@ WHERE (
     (main.Type = 'ticket')
 ) AND (
     (
-	(Users_3.EmailAddress = '22')
-	    AND
-	(Groups_1.Domain = 'RT::Ticket-Role')
-	    AND
-	(Groups_1.Type = 'RequestorGroup')
+        (Users_3.EmailAddress = '22')
+            AND
+        (Groups_1.Domain = 'RT::Ticket-Role')
+            AND
+        (Groups_1.Type = 'RequestorGroup')
     )
 ) AND
     Groups_1.Instance = main.id
diff --git a/lib/RT/Tickets_SQL.pm b/lib/RT/Tickets_SQL.pm
index ec1bb49..a0340d8 100644
--- a/lib/RT/Tickets_SQL.pm
+++ b/lib/RT/Tickets_SQL.pm
@@ -100,7 +100,7 @@ sub _SQLJoin {
   my $this = shift;
 
   $this->SUPER::Join(@_,
-		     SUBCLAUSE => 'ticketsql');
+                     SUBCLAUSE => 'ticketsql');
 }
 
 # Helpers
diff --git a/lib/RT/Topic.pm b/lib/RT/Topic.pm
index 2e4840b..f38e602 100644
--- a/lib/RT/Topic.pm
+++ b/lib/RT/Topic.pm
@@ -357,17 +357,17 @@ sub _CoreAccessible {
     {
      
         id =>
-		{read => 1, type => 'int(11)', default => ''},
+                {read => 1, type => 'int(11)', default => ''},
         Parent => 
-		{read => 1, write => 1, type => 'int(11)', default => ''},
+                {read => 1, write => 1, type => 'int(11)', default => ''},
         Name => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         Description => 
-		{read => 1, write => 1, type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, type => 'varchar(255)', default => ''},
         ObjectType => 
-		{read => 1, write => 1, type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, type => 'varchar(64)', default => ''},
         ObjectId => 
-		{read => 1, write => 1, type => 'int(11)', default => '0'},
+                {read => 1, write => 1, type => 'int(11)', default => '0'},
 
  }
 };
diff --git a/lib/RT/Transaction.pm b/lib/RT/Transaction.pm
index 894eb46..496ce4c 100644
--- a/lib/RT/Transaction.pm
+++ b/lib/RT/Transaction.pm
@@ -146,11 +146,11 @@ sub Create {
         OldValue  => $args{'OldValue'},
         NewValue  => $args{'NewValue'},
         Created   => $args{'Created'},
-	ObjectType => $args{'ObjectType'},
-	ObjectId => $args{'ObjectId'},
-	ReferenceType => $args{'ReferenceType'},
-	OldReference => $args{'OldReference'},
-	NewReference => $args{'NewReference'},
+        ObjectType => $args{'ObjectType'},
+        ObjectId => $args{'ObjectId'},
+        ReferenceType => $args{'ReferenceType'},
+        OldReference => $args{'OldReference'},
+        NewReference => $args{'NewReference'},
     );
 
     # Parameters passed in during an import that we probably don't want to touch, otherwise
@@ -401,14 +401,14 @@ Returns a hashref of addresses related to this transaction. See L<RT::Attachment
 =cut
 
 sub Addresses {
-	my $self = shift;
+    my $self = shift;
 
-	if (my $attach = $self->Attachments->First) {	
-		return $attach->Addresses;
-	}
-	else {
-		return {};
-	}
+    if (my $attach = $self->Attachments->First) {
+        return $attach->Addresses;
+    }
+    else {
+        return {};
+    }
 
 }
 
@@ -1248,7 +1248,7 @@ sub UpdateCustomFields {
         next
           unless ( $arg =~
             /^(?:Object-RT::Transaction--)?CustomField-(\d+)/ );
-	next if $arg =~ /-Magic$/;
+        next if $arg =~ /-Magic$/;
         my $cfid   = $1;
         my $values = $args->{$arg};
         foreach
@@ -1659,33 +1659,33 @@ sub _CoreAccessible {
     {
 
         id =>
-		{read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         ObjectType =>
-		{read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 64,  is_blob => 0,  is_numeric => 0,  type => 'varchar(64)', default => ''},
         ObjectId =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         TimeTaken =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Type =>
-		{read => 1, write => 1, sql_type => 12, length => 20,  is_blob => 0,  is_numeric => 0,  type => 'varchar(20)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 20,  is_blob => 0,  is_numeric => 0,  type => 'varchar(20)', default => ''},
         Field =>
-		{read => 1, write => 1, sql_type => 12, length => 40,  is_blob => 0,  is_numeric => 0,  type => 'varchar(40)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 40,  is_blob => 0,  is_numeric => 0,  type => 'varchar(40)', default => ''},
         OldValue =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         NewValue =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         ReferenceType =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         OldReference =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         NewReference =>
-		{read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
+                {read => 1, write => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => ''},
         Data =>
-		{read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
+                {read => 1, write => 1, sql_type => 12, length => 255,  is_blob => 0,  is_numeric => 0,  type => 'varchar(255)', default => ''},
         Creator =>
-		{read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
+                {read => 1, auto => 1, sql_type => 4, length => 11,  is_blob => 0,  is_numeric => 1,  type => 'int(11)', default => '0'},
         Created =>
-		{read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
+                {read => 1, auto => 1, sql_type => 11, length => 0,  is_blob => 0,  is_numeric => 0,  type => 'datetime', default => ''},
 
  }
 };
diff --git a/lib/RT/Transactions.pm b/lib/RT/Transactions.pm
index d0f93fd..cd3a84f 100644
--- a/lib/RT/Transactions.pm
+++ b/lib/RT/Transactions.pm
@@ -84,9 +84,9 @@ sub _Init   {
   
   # By default, order by the date of the transaction, rather than ID.
   $self->OrderByCols( { FIELD => 'Created',
-			ORDER => 'ASC' },
-		      { FIELD => 'id',
-			ORDER => 'ASC' } );
+                        ORDER => 'ASC' },
+                      { FIELD => 'id',
+                        ORDER => 'ASC' } );
 
   return ( $self->SUPER::_Init(@_));
 }
@@ -133,25 +133,25 @@ sub LimitToTicket {
 
 sub Next {
     my $self = shift;
- 	
+
     my $Transaction = $self->SUPER::Next();
     if ((defined($Transaction)) and (ref($Transaction))) {
-    	# If the user can see the transaction's type, then they can 
-	#  see the transaction and we should hand it back.
-	if ($Transaction->Type) {
-	    return($Transaction);
-	}
-
-	#If the user doesn't have the right to show this ticket
-	else {	
-	    return($self->Next());
-	}
+        # If the user can see the transaction's type, then they can
+        #  see the transaction and we should hand it back.
+        if ($Transaction->Type) {
+            return($Transaction);
+        }
+
+        #If the user doesn't have the right to show this ticket
+        else {
+            return($self->Next());
+        }
     }
 
     #if there never was any ticket
     else {
-	return(undef);
-    }	
+        return(undef);
+    }
 }
 
 
diff --git a/lib/RT/URI.pm b/lib/RT/URI.pm
index 284a75e..45f2f74 100644
--- a/lib/RT/URI.pm
+++ b/lib/RT/URI.pm
@@ -141,33 +141,33 @@ Returns true if everything is ok, otherwise false
 
 sub FromURI {
     my $self = shift;
-    my $uri = shift;    
+    my $uri = shift;
 
     return undef unless ($uri);
 
     my $scheme;
     # Special case: integers passed in as URIs must be ticket ids
     if ($uri =~ /^(\d+)$/) {
-	$scheme = "fsck.com-rt";
+        $scheme = "fsck.com-rt";
     } elsif ($uri =~ /^((?!javascript|data)(?:\w|\.|-)+?):/i) {
-	$scheme = $1;
+        $scheme = $1;
     }
     else {
         $self->{resolver} = RT::URI::base->new( $self->CurrentUser ); # clear resolver
         $RT::Logger->warning("Could not determine a URI scheme for $uri");
         return (undef);
     }
-     
-    # load up a resolver object for this scheme  
+
+    # load up a resolver object for this scheme
     $self->_GetResolver($scheme);
-    
+
     unless ($self->Resolver->ParseURI($uri)) {
         $RT::Logger->warning( "Resolver "
               . ref( $self->Resolver )
               . " could not parse $uri, maybe Organization config was changed?"
         );
         $self->{resolver} = RT::URI::base->new( $self->CurrentUser ); # clear resolver
-    	return (undef);
+        return (undef);
     }
 
     return(1);
diff --git a/lib/RT/URI/a.pm b/lib/RT/URI/a.pm
index ad812b4..3b1e41a 100644
--- a/lib/RT/URI/a.pm
+++ b/lib/RT/URI/a.pm
@@ -71,11 +71,11 @@ sub ParseURI {
     # articles after stripping off the a: prefix.
 
     if ($uri =~ /^$scheme:(\d+)/) {
-            my $value = $1;
-	return $self->SUPER::ParseURI($value);
+        my $value = $1;
+        return $self->SUPER::ParseURI($value);
     } else {
-	$self->{'uri'} = $uri;
-	return undef;
+        $self->{'uri'} = $uri;
+        return undef;
     }
 }
 
diff --git a/lib/RT/URI/fsck_com_article.pm b/lib/RT/URI/fsck_com_article.pm
index f278c98..dcd296c 100644
--- a/lib/RT/URI/fsck_com_article.pm
+++ b/lib/RT/URI/fsck_com_article.pm
@@ -100,39 +100,36 @@ sub ParseURI {
     my $self = shift;
     my $uri = shift;
 
-	my $article;
- 
- 	if ($uri =~ /^(\d+)$/) {
- 		$article = RT::Article->new($self->CurrentUser);
- 		$article->Load($uri);	
- 		$self->{'uri'} = $article->URI;
- 	}
- 	else {
-	    $self->{'uri'} = $uri;
- 	}
- 
+    my $article;
+
+    if ($uri =~ /^(\d+)$/) {
+        $article = RT::Article->new($self->CurrentUser);
+        $article->Load($uri);
+        $self->{'uri'} = $article->URI;
+    }
+    else {
+        $self->{'uri'} = $uri;
+    }
+
        #If it's a local URI, load the article object and return its URI
     if ( $self->IsLocal) {
-   
         my $local_uri_prefix = $self->LocalURIPrefix;
-    	if ($self->{'uri'} =~ /^$local_uri_prefix(\d+)$/) {
-    		my $id = $1;
-    	
-    
-	        $article = RT::Article->new( $self->CurrentUser );
-    	    $article->Load($id);
-
-    	    #If we couldn't find a article, return undef.
-    	    unless ( defined $article->Id ) {
-    	    	return undef;
-    	    }
-    	    } else {
-    	    return undef;
-    	    }	
+        if ($self->{'uri'} =~ /^$local_uri_prefix(\d+)$/) {
+            my $id = $1;
+            $article = RT::Article->new( $self->CurrentUser );
+            $article->Load($id);
+
+            #If we couldn't find a article, return undef.
+            unless ( defined $article->Id ) {
+                return undef;
+            }
+            } else {
+                return undef;
+            }
     }
- 
- 	$self->{'object'} = $article;
-  	return ($article->Id);
+
+    $self->{'object'} = $article;
+    return ($article->Id);
 }
 
 =head2 IsLocal 
@@ -143,14 +140,14 @@ Returns undef otherwise.
 =cut
 
 sub IsLocal {
-	my $self = shift;
-        my $local_uri_prefix = $self->LocalURIPrefix;
-	if ($self->{'uri'} =~ /^$local_uri_prefix/) {
-		return 1;
+    my $self = shift;
+    my $local_uri_prefix = $self->LocalURIPrefix;
+    if ($self->{'uri'} =~ /^$local_uri_prefix/) {
+        return 1;
+    }
+    else {
+        return undef;
     }
-	else {
-		return undef;
-	}
 }
 
 
@@ -175,7 +172,7 @@ Return the URI scheme for RT articles
 
 sub Scheme {
     my $self = shift;
-	return "fsck.com-article";
+    return "fsck.com-article";
 }
 
 =head2 HREF
diff --git a/sbin/rt-setup-database.in b/sbin/rt-setup-database.in
index f0afd08..657143b 100644
--- a/sbin/rt-setup-database.in
+++ b/sbin/rt-setup-database.in
@@ -445,10 +445,10 @@ sub action_upgrade {
             return ( $ret, $msg ) unless $ret;
         }
 
-	# XXX: Another connect since the insert called
-	# previous to this step will disconnect.
+        # XXX: Another connect since the insert called
+        # previous to this step will disconnect.
 
-	RT->ConnectToDatabase();
+        RT->ConnectToDatabase();
 
         RT->System->AddUpgradeHistory($package => {
             action => 'upgrade',
diff --git a/sbin/rt-shredder.in b/sbin/rt-shredder.in
index 5d5db4c..a8b8041 100644
--- a/sbin/rt-shredder.in
+++ b/sbin/rt-shredder.in
@@ -146,7 +146,7 @@ my $shredder = RT::Shredder->new;
         file_name    => $opt{'sqldump'},
         from_storage => 0,
     } ) };
-	if( $@ ) {
+        if( $@ ) {
         print STDERR "ERROR: Couldn't open SQL dump file: $@\n";
         exit 1 if $opt{'sqldump'};
 
@@ -154,7 +154,7 @@ my $shredder = RT::Shredder->new;
         unless( $opt{'force'} ) {
             exit 0 unless prompt_yN( "Do you want to proceed?" );
         }
-	} else {
+        } else {
         print "SQL dump file is '". $plugin->FileName ."'\n";
     }
 }
@@ -175,95 +175,95 @@ if( $@ ) {
 
 sub prompt_delete_objs
 {
-	my( $objs ) = @_;
-	unless( @$objs ) {
-		print "Objects list is empty, try refine search options\n";
-		exit 0;
-	}
-	my $list = "Next ". scalar( @$objs ) ." objects would be deleted:\n";
-	foreach my $o( @$objs ) {
-		$list .= "\t". $o->_AsString ." object\n";
-	}
-	print $list;
-	exit(0) unless prompt_yN( "Do you want to proceed?" );
+    my( $objs ) = @_;
+    unless( @$objs ) {
+        print "Objects list is empty, try refine search options\n";
+        exit 0;
+    }
+    my $list = "Next ". scalar( @$objs ) ." objects would be deleted:\n";
+    foreach my $o( @$objs ) {
+        $list .= "\t". $o->_AsString ." object\n";
+    }
+    print $list;
+    exit(0) unless prompt_yN( "Do you want to proceed?" );
 }
 
 sub prompt_yN
 {
-	my $text = shift;
-	print "$text [y/N] ";
-	unless( <STDIN> =~ /^(?:y|yes)$/i ) {
-		return 0;
-	}
-	return 1;
+    my $text = shift;
+    print "$text [y/N] ";
+    unless( <STDIN> =~ /^(?:y|yes)$/i ) {
+        return 0;
+    }
+    return 1;
 }
 
 sub usage
 {
-	require RT::Shredder::POD;
-	RT::Shredder::POD::shredder_cli( $0, \*STDOUT );
-	exit 1;
+    require RT::Shredder::POD;
+    RT::Shredder::POD::shredder_cli( $0, \*STDOUT );
+    exit 1;
 }
 
 sub parse_args
 {
-	my $tmp;
-	Getopt::Long::Configure( "pass_through" );
-	my @objs = ();
-	if( GetOptions( 'object=s' => \@objs ) && @objs ) {
-		print STDERR "Option --object had been deprecated, use plugin 'Objects' instead\n";
+    my $tmp;
+    Getopt::Long::Configure( "pass_through" );
+    my @objs = ();
+    if( GetOptions( 'object=s' => \@objs ) && @objs ) {
+        print STDERR "Option --object had been deprecated, use plugin 'Objects' instead\n";
         exit(1);
-	}
-
-	my @plugins = ();
-	if( GetOptions( 'plugin=s' => \@plugins ) && @plugins ) {
-		$opt{'plugin'} = \@plugins;
-		foreach my $str( @plugins ) {
-			if( $str =~ /^\s*list\s*$/ ) {
-				show_plugin_list();
-			} elsif( $str =~ /^\s*help-(\w+)\s*$/ ) {
-				show_plugin_help( $1 );
-			} elsif( $str =~ /^(\w+)(=.*)?$/ && !$plugins{$1} ) {
-				print "Couldn't find plugin '$1'\n";
-				show_plugin_list();
-			}
-		}
-	}
-
-	# other options make no sense without previouse
-	usage() unless keys %opt;
-
-	if( GetOptions( 'force' => \$tmp ) && $tmp ) {
-		$opt{'force'}++;
-	}
-	$tmp = undef;
-	if( GetOptions( 'sqldump=s' => \$tmp ) && $tmp ) {
-		$opt{'sqldump'} = $tmp;
-	}
-	return;
+    }
+
+    my @plugins = ();
+    if( GetOptions( 'plugin=s' => \@plugins ) && @plugins ) {
+        $opt{'plugin'} = \@plugins;
+        foreach my $str( @plugins ) {
+            if( $str =~ /^\s*list\s*$/ ) {
+                show_plugin_list();
+            } elsif( $str =~ /^\s*help-(\w+)\s*$/ ) {
+                show_plugin_help( $1 );
+            } elsif( $str =~ /^(\w+)(=.*)?$/ && !$plugins{$1} ) {
+                print "Couldn't find plugin '$1'\n";
+                show_plugin_list();
+            }
+        }
+    }
+
+    # other options make no sense without previouse
+    usage() unless keys %opt;
+
+    if( GetOptions( 'force' => \$tmp ) && $tmp ) {
+        $opt{'force'}++;
+    }
+    $tmp = undef;
+    if( GetOptions( 'sqldump=s' => \$tmp ) && $tmp ) {
+        $opt{'sqldump'} = $tmp;
+    }
+    return;
 }
 
 sub process_plugins
 {
-	my $shredder = shift;
-
-	my @res;
-	foreach my $str( @{ $opt{'plugin'} } ) {
-		my $plugin = RT::Shredder::Plugin->new;
-		my( $status, $msg ) = $plugin->LoadByString( $str );
-		unless( $status ) {
-			print STDERR "Couldn't load plugin\n";
-			print STDERR "Error: $msg\n";
-			exit(1);
-		}
+    my $shredder = shift;
+
+    my @res;
+    foreach my $str( @{ $opt{'plugin'} } ) {
+        my $plugin = RT::Shredder::Plugin->new;
+        my( $status, $msg ) = $plugin->LoadByString( $str );
+        unless( $status ) {
+            print STDERR "Couldn't load plugin\n";
+            print STDERR "Error: $msg\n";
+            exit(1);
+        }
         if ( lc $plugin->Type eq 'search' ) {
             push @res, _process_search_plugin( $shredder, $plugin );
         }
         elsif ( lc $plugin->Type eq 'dump' ) {
             _process_dump_plugin( $shredder, $plugin );
         }
-	}
-	return RT::Shredder->CastObjectsToRecords( Objects => \@res );
+    }
+    return RT::Shredder->CastObjectsToRecords( Objects => \@res );
 }
 
 sub _process_search_plugin {
@@ -294,22 +294,22 @@ sub _process_dump_plugin {
 
 sub show_plugin_list
 {
-	print "Plugins list:\n";
-	print "\t$_\n" foreach( grep !/^Base$/, keys %plugins );
-	exit(1);
+    print "Plugins list:\n";
+    print "\t$_\n" foreach( grep !/^Base$/, keys %plugins );
+    exit(1);
 }
 
 sub show_plugin_help
 {
-	my( $name ) = @_;
-	require RT::Shredder::POD;
-	unless( $plugins{ $name } ) {
-		print "Couldn't find plugin '$name'\n";
-		show_plugin_list();
-	}
-	RT::Shredder::POD::plugin_cli( $plugins{'Base'}, \*STDOUT, 1 );
-	RT::Shredder::POD::plugin_cli( $plugins{ $name }, \*STDOUT );
-	exit(1);
+    my( $name ) = @_;
+    require RT::Shredder::POD;
+    unless( $plugins{ $name } ) {
+        print "Couldn't find plugin '$name'\n";
+        show_plugin_list();
+    }
+    RT::Shredder::POD::plugin_cli( $plugins{'Base'}, \*STDOUT, 1 );
+    RT::Shredder::POD::plugin_cli( $plugins{ $name }, \*STDOUT );
+    exit(1);
 }
 
 exit(0);
diff --git a/share/html/Admin/Elements/EditCustomField b/share/html/Admin/Elements/EditCustomField
index e461921..108d375 100644
--- a/share/html/Admin/Elements/EditCustomField
+++ b/share/html/Admin/Elements/EditCustomField
@@ -101,19 +101,19 @@ if (! $CustomField ) {
 } else {
 
     if ($CustomField eq 'new') {
-      my ($val, $msg) =  $CustomFieldObj->Create(Queue => $Queue, 
-                                                 Name => $Name, 
+      my ($val, $msg) =  $CustomFieldObj->Create(Queue => $Queue,
+                                                 Name => $Name,
                                                  Type => $Type,
                                                  Description => $Description,
-						 );
-      
+                                             );
+
       # if there is an error, then abort.  But since at this point there's
       # stuff already printed, clear it out.
       # (This only works in conjunction with temporarily turning autoflush
       #  off in the files that use this component.)
       unless ($val) {
-	  $m->clear_buffer;
-	  Abort(loc("Could not create CustomField: [_1]", $msg), SuppressHeader => 1);
+          $m->clear_buffer;
+          Abort(loc("Could not create CustomField: [_1]", $msg), SuppressHeader => 1);
       }
       push @results, $msg;
       $CustomFieldObj->SetSortOrder($CustomFieldObj->id);
diff --git a/share/html/Admin/Elements/SelectSingleOrMultiple b/share/html/Admin/Elements/SelectSingleOrMultiple
index bf28243..f115bee 100644
--- a/share/html/Admin/Elements/SelectSingleOrMultiple
+++ b/share/html/Admin/Elements/SelectSingleOrMultiple
@@ -48,7 +48,7 @@
   <select name="<%$Name%>">
     <option value="1" <%$SingleDefault|n%>><&|/l&>Single</&></option>
     <option value="0" <%$MultipleDefault|n%>><&|/l&>Multiple</&></option>
-  </select>	
+  </select>
 
 
 <%INIT>
diff --git a/share/html/Admin/Global/Template.html b/share/html/Admin/Global/Template.html
index be8501b..d13145c 100644
--- a/share/html/Admin/Global/Template.html
+++ b/share/html/Admin/Global/Template.html
@@ -94,8 +94,8 @@ else {
 if ($TemplateObj->Id()) {
   my @attribs = qw( Name Description Queue Type Content );
   my @aresults = UpdateRecordObject( AttributesRef => \@attribs, 
-				     Object => $TemplateObj, 
-				     ARGSRef => \%ARGS);
+                                     Object => $TemplateObj, 
+                                     ARGSRef => \%ARGS);
   push @results, @aresults;
 
   my ($ok, $msg) = $TemplateObj->CompileCheck;
diff --git a/share/html/Admin/Groups/Modify.html b/share/html/Admin/Groups/Modify.html
index 5ac8de5..8367d87 100644
--- a/share/html/Admin/Groups/Modify.html
+++ b/share/html/Admin/Groups/Modify.html
@@ -103,7 +103,7 @@ if ($Create) {
     $title = loc("Create a new group");
 } else {
     if ($id eq 'new' ) {
-	my ($create_id, $create_msg) = $Group->CreateUserDefinedGroup(Name => $Name );
+        my ($create_id, $create_msg) = $Group->CreateUserDefinedGroup(Name => $Name );
         if ($create_id) {
             $id = $Group->Id;
             push @results, $create_msg;
@@ -111,25 +111,25 @@ if ($Create) {
             push @results, loc("Group could not be created: [_1]", $create_msg);
         }
     } else {
-	$Group->Load($id) || Abort('Could not load group');
+        $Group->Load($id) || Abort('Could not load group');
     }
 
     if ($Group->Id) {
-	$title = loc("Modify the group [_1]", $Group->Name);
+        $title = loc("Modify the group [_1]", $Group->Name);
     }
 
     # If the create failed
     else {
-	$title = loc("Create a new group");
-	$Create = 1;
+        $title = loc("Create a new group");
+        $Create = 1;
     }
 }
 
 if ($Group->Id) {
     my @fields = qw(Description Name );
     my @fieldresults = UpdateRecordObject ( AttributesRef => \@fields,
-					    Object => $Group,
-					    ARGSRef => \%ARGS );
+                                            Object => $Group,
+                                            ARGSRef => \%ARGS );
     push (@results, at fieldresults);
     push @results, ProcessObjectCustomFieldUpdates( ARGSRef => \%ARGS, Object => $Group );
 
diff --git a/share/html/Admin/Groups/index.html b/share/html/Admin/Groups/index.html
index 6a15471..1028196 100644
--- a/share/html/Admin/Groups/index.html
+++ b/share/html/Admin/Groups/index.html
@@ -107,18 +107,18 @@ if ($FindDisabledGroups) {
 if (length $GroupString) {
     $caption = loc("Groups matching search criteria");
     if ($GroupField =~ /^CustomField-(\d+)/) {
-	$Groups->LimitCustomField(
-	    CUSTOMFIELD => $1,
-	    OPERATOR => $GroupOp,
-	    VALUE => $GroupString,
-	); 
+        $Groups->LimitCustomField(
+            CUSTOMFIELD => $1,
+            OPERATOR => $GroupOp,
+            VALUE => $GroupString,
+        );
     }
     else {
-	$Groups->Limit(
-	    FIELD => $GroupField,
-	    OPERATOR => $GroupOp,
-	    VALUE => $GroupString,
-	); 
+        $Groups->Limit(
+            FIELD => $GroupField,
+            OPERATOR => $GroupOp,
+            VALUE => $GroupString,
+        );
     }
     RT::Interface::Web::Redirect(RT->Config->Get('WebURL')."Admin/Groups/Modify.html?id=".$Groups->First->id)
           if $Groups->Count == 1 and $Groups->First;
diff --git a/share/html/Admin/Tools/Shredder/Elements/PluginHelp b/share/html/Admin/Tools/Shredder/Elements/PluginHelp
index 7719ec0..99c519e 100644
--- a/share/html/Admin/Tools/Shredder/Elements/PluginHelp
+++ b/share/html/Admin/Tools/Shredder/Elements/PluginHelp
@@ -59,8 +59,8 @@ my %plugins = $plugin_obj->List;
 <%INIT>
 my $file = $plugins{ $Plugin };
 unless( $file ) {
-	$RT::Logger->error( "Couldn't find plugin '$Plugin'" );
-	return;
+    $RT::Logger->error( "Couldn't find plugin '$Plugin'" );
+    return;
 }
 
 use RT::Shredder::POD qw();
diff --git a/share/html/Admin/Tools/Shredder/autohandler b/share/html/Admin/Tools/Shredder/autohandler
index 9552064..72a089d 100644
--- a/share/html/Admin/Tools/Shredder/autohandler
+++ b/share/html/Admin/Tools/Shredder/autohandler
@@ -47,13 +47,13 @@
 %# END BPS TAGGED BLOCK }}}
 <%INIT>
 unless( $session{'CurrentUser'}->HasRight( Right => 'SuperUser', Object => $RT::System ) ) {
-	return $m->comp( 'Elements/Error/NoRights' );
+    return $m->comp( 'Elements/Error/NoRights' );
 }
 
 use RT::Shredder ();
 my $path = RT::Shredder->StoragePath;
 unless( -d $path && -w _ ) {
-	return $m->comp( 'Elements/Error/NoStorage', Path => $path );
+    return $m->comp( 'Elements/Error/NoStorage', Path => $path );
 }
 
 $m->call_next(%ARGS);
diff --git a/share/html/Admin/Users/Modify.html b/share/html/Admin/Users/Modify.html
index e321ab6..6cb0eb2 100644
--- a/share/html/Admin/Users/Modify.html
+++ b/share/html/Admin/Users/Modify.html
@@ -240,59 +240,59 @@ if ($Create) {
 else {
 
     if ( defined $id && $id eq 'new') {
-	( $val, $msg ) = $UserObj->Create(
-	    Name                  => $Name,
-	    EmailAddress          => $ARGS{'EmailAddress'},
-	    Name                  => $ARGS{'Name'},
-	    Comments              => $ARGS{'Comments'},
-	    Signature             => $ARGS{'Signature'},
-	    EmailAddress          => $ARGS{'EmailAddress'},
-	    FreeformContactInfo   => $ARGS{'FreeformContactInfo'},
-	    Organization          => $ARGS{'Organization'},
-	    RealName              => $ARGS{'RealName'},
-	    NickName              => $ARGS{'NickName'},
-	    Lang                  => $ARGS{'Lang'},
-	    EmailEncoding         => $ARGS{'EmailEncoding'},
-	    WebEncoding           => $ARGS{'WebEncoding'},
-	    ExternalContactInfoId => $ARGS{'ExternalContactInfoId'},
-	    ContactInfoSystem     => $ARGS{'ContactInfoSystem'},
-	    Gecos                 => $ARGS{'Gecos'},
-	    ExternalAuthId        => $ARGS{'ExternalAuthId'},
-	    AuthSystem            => $ARGS{'AuthSystem'},
-	    HomePhone             => $ARGS{'HomePhone'},
-	    WorkPhone             => $ARGS{'WorkPhone'},
-	    MobilePhone           => $ARGS{'MobilePhone'},
-	    PagerPhone            => $ARGS{'PagerPhone'},
-	    Address1              => $ARGS{'Address1'},
-	    Address2              => $ARGS{'Address2'},
-	    City                  => $ARGS{'City'},
-	    State                 => $ARGS{'State'},
-	    Zip                   => $ARGS{'Zip'},
-	    Country               => $ARGS{'Country'},
-	    Privileged           => $ARGS{'Privileged'},
-	    Disabled            => ($ARGS{'Enabled'} ? 0 : 1)
-	);
-
-	if ($val) {
-		push @results, $msg;
+        ( $val, $msg ) = $UserObj->Create(
+            Name                  => $Name,
+            EmailAddress          => $ARGS{'EmailAddress'},
+            Name                  => $ARGS{'Name'},
+            Comments              => $ARGS{'Comments'},
+            Signature             => $ARGS{'Signature'},
+            EmailAddress          => $ARGS{'EmailAddress'},
+            FreeformContactInfo   => $ARGS{'FreeformContactInfo'},
+            Organization          => $ARGS{'Organization'},
+            RealName              => $ARGS{'RealName'},
+            NickName              => $ARGS{'NickName'},
+            Lang                  => $ARGS{'Lang'},
+            EmailEncoding         => $ARGS{'EmailEncoding'},
+            WebEncoding           => $ARGS{'WebEncoding'},
+            ExternalContactInfoId => $ARGS{'ExternalContactInfoId'},
+            ContactInfoSystem     => $ARGS{'ContactInfoSystem'},
+            Gecos                 => $ARGS{'Gecos'},
+            ExternalAuthId        => $ARGS{'ExternalAuthId'},
+            AuthSystem            => $ARGS{'AuthSystem'},
+            HomePhone             => $ARGS{'HomePhone'},
+            WorkPhone             => $ARGS{'WorkPhone'},
+            MobilePhone           => $ARGS{'MobilePhone'},
+            PagerPhone            => $ARGS{'PagerPhone'},
+            Address1              => $ARGS{'Address1'},
+            Address2              => $ARGS{'Address2'},
+            City                  => $ARGS{'City'},
+            State                 => $ARGS{'State'},
+            Zip                   => $ARGS{'Zip'},
+            Country               => $ARGS{'Country'},
+            Privileged           => $ARGS{'Privileged'},
+            Disabled            => ($ARGS{'Enabled'} ? 0 : 1)
+        );
+
+        if ($val) {
+                push @results, $msg;
         push @results, ProcessObjectCustomFieldUpdates( ARGSRef => \%ARGS, Object => $UserObj );
-	} else {
-		push @results, loc('User could not be created: [_1]', $msg);
-	}
+        } else {
+                push @results, loc('User could not be created: [_1]', $msg);
+        }
     } else {
-	    $UserObj->Load($id) || $UserObj->Load($Name) 
+            $UserObj->Load($id) || $UserObj->Load($Name) 
             || Abort("Couldn't load user '" . ( $Name || '') . "'");
         $val = $UserObj->Id();
     }
 
     if ($val) {
-	$title = loc("Modify the user [_1]", $UserObj->Name);
+        $title = loc("Modify the user [_1]", $UserObj->Name);
     }
 
     # If the create failed
     else {
-	$title = loc("Create a new user");
-	$Create = 1;
+        $title = loc("Create a new user");
+        $Create = 1;
     }
 }
 
@@ -304,15 +304,15 @@ $m->callback( %ARGS, CallbackName => 'BeforeUpdate', User => $UserObj, ARGSRef =
 if ($UserObj->Id && $id ne 'new') {
 
     my @fields = qw(Name Comments Signature EmailAddress FreeformContactInfo 
-		    Organization RealName NickName Lang EmailEncoding WebEncoding 
-		    ExternalContactInfoId ContactInfoSystem Gecos ExternalAuthId 
-		    AuthSystem HomePhone WorkPhone MobilePhone PagerPhone Address1
-		    Address2 City State Zip Country 
-		   );
+                    Organization RealName NickName Lang EmailEncoding WebEncoding 
+                    ExternalContactInfoId ContactInfoSystem Gecos ExternalAuthId 
+                    AuthSystem HomePhone WorkPhone MobilePhone PagerPhone Address1
+                    Address2 City State Zip Country 
+                   );
 
     my @fieldresults = UpdateRecordObject ( AttributesRef => \@fields,
-					    Object => $UserObj,
-					    ARGSRef => \%ARGS );
+                                            Object => $UserObj,
+                                            ARGSRef => \%ARGS );
     push (@results, at fieldresults);
     push @results, ProcessObjectCustomFieldUpdates( ARGSRef => \%ARGS, Object => $UserObj );
 
diff --git a/share/html/Approvals/Elements/PendingMyApproval b/share/html/Approvals/Elements/PendingMyApproval
index c4e19a8..252031f 100644
--- a/share/html/Approvals/Elements/PendingMyApproval
+++ b/share/html/Approvals/Elements/PendingMyApproval
@@ -90,24 +90,24 @@ foreach ($tickets, $group_tickets) {
     $_->Limit( FIELD      => 'Type', VALUE => 'approval' );
 
     if ( $ARGS{'ShowResolved'} ) {
-	$_->LimitStatus( VALUE => 'resolved' );
+        $_->LimitStatus( VALUE => 'resolved' );
     }
     if ( $ARGS{'ShowRejected'} ) {
-	$_->LimitStatus( VALUE => 'rejected' );
+        $_->LimitStatus( VALUE => 'rejected' );
     }
     if ( $ARGS{'ShowPending'} || ( !$ARGS{'ShowRejected'} && !$ARGS{'Resolved'} ) ) {
-	$_->LimitStatus( VALUE => 'open' );
-	$_->LimitStatus( VALUE => 'new' );
-	$_->LimitStatus( VALUE => 'stalled' );
+        $_->LimitStatus( VALUE => 'open' );
+        $_->LimitStatus( VALUE => 'new' );
+        $_->LimitStatus( VALUE => 'stalled' );
     }
 
     if ( $ARGS{'CreatedBefore'} ) {
-	$created_before->Set( Format => 'unknown', Value => $ARGS{'CreatedBefore'} );
-	$_->LimitCreated( OPERATOR => "<=", VALUE => $created_before->ISO );
+        $created_before->Set( Format => 'unknown', Value => $ARGS{'CreatedBefore'} );
+        $_->LimitCreated( OPERATOR => "<=", VALUE => $created_before->ISO );
     }
     if ( $ARGS{'CreatedAfter'} ) {
-	$created_after->Set( Format => 'unknown', Value => $ARGS{'CreatedAfter'} );
-	$_->LimitCreated( OPERATOR => ">=", VALUE => $created_after->ISO );
+        $created_after->Set( Format => 'unknown', Value => $ARGS{'CreatedAfter'} );
+        $_->LimitCreated( OPERATOR => ">=", VALUE => $created_after->ISO );
     }
     $_->OrderBy( FIELD => 'id' );
 }
diff --git a/share/html/Approvals/Elements/ShowDependency b/share/html/Approvals/Elements/ShowDependency
index 35c9da7..eebacfd 100644
--- a/share/html/Approvals/Elements/ShowDependency
+++ b/share/html/Approvals/Elements/ShowDependency
@@ -62,16 +62,16 @@ while (my $link = $approving->Next()) {
     my $dep  = $m->scomp('ShowDependency', Ticket => $link->BaseObj, _seen => $_seen);
 
     if ($type eq 'approval') {
-	$head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("Approval #[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject));
-	$text .= $head;
-	$text .= $m->scomp('/Ticket/Elements/ShowCustomFields', Ticket => $link->BaseObj);
+        $head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("Approval #[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject));
+        $text .= $head;
+        $text .= $m->scomp('/Ticket/Elements/ShowCustomFields', Ticket => $link->BaseObj);
     } elsif ($type eq 'ticket') {
-	$head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("Ticket #[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject));
-	$text .= $head;
-	$text .= $m->scomp('/Ticket/Elements/ShowSummary', Ticket => $link->BaseObj);
+        $head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("Ticket #[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject));
+        $text .= $head;
+        $text .= $m->scomp('/Ticket/Elements/ShowSummary', Ticket => $link->BaseObj);
     } else {
-	$head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("#[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject));
-	$text .= $head;
+        $head .= $m->scomp('/Widgets/TitleBoxStart', title => loc("#[_1]: [_2]", $link->BaseObj->Id, $link->BaseObj->Subject));
+        $text .= $head;
     }
 
     $text .= $m->scomp('/Elements/ShowHistory' , Object => $link->BaseObj, ShowTitle => 0, ShowHeaders => 0, ShowDisplayModes => 0, ShowTitleBarCommands => 0);
@@ -81,16 +81,16 @@ while (my $link = $approving->Next()) {
     $text .= $dep;
     $text .= '</a>';
     $show{$link->BaseObj->Id} = {
-	text => $text,
-	head => $head,
+        text => $text,
+        head => $head,
     };
 }
 
 my $refer;
 foreach my $id (sort keys %show) {
     if ($_seen->{$id}++) {
-	$refer .= "<a href='#txn-$id'>" . $show{$id}{head} . "</a>";
-	next;
+        $refer .= "<a href='#txn-$id'>" . $show{$id}{head} . "</a>";
+        next;
     }
 
     $m->print($show{$id}{text});
diff --git a/share/html/Approvals/index.html b/share/html/Approvals/index.html
index c72e9af..f08453a 100644
--- a/share/html/Approvals/index.html
+++ b/share/html/Approvals/index.html
@@ -66,9 +66,9 @@ foreach my $arg ( keys %ARGS ) {
 
     if ( $ARGS{ "Approval-" . $ticket->Id . "-Notes" } ) {
         my $notes = MIME::Entity->build(
-	    Data => [ $ARGS{ "Approval-" . $ticket->Id . "-Notes" } ]
-	);
-	RT::I18N::SetMIMEEntityToUTF8($notes); # convert text parts into utf-8
+            Data => [ $ARGS{ "Approval-" . $ticket->Id . "-Notes" } ]
+        );
+        RT::I18N::SetMIMEEntityToUTF8($notes); # convert text parts into utf-8
 
         my ( $notesval, $notesmsg ) = $ticket->Correspond( MIMEObj => $notes );
         if ($notesval) {
diff --git a/share/html/Articles/Article/Elements/ShowSavedSearches b/share/html/Articles/Article/Elements/ShowSavedSearches
index 8ced74b..55a6954 100644
--- a/share/html/Articles/Article/Elements/ShowSavedSearches
+++ b/share/html/Articles/Article/Elements/ShowSavedSearches
@@ -53,8 +53,7 @@
 %                                       Object=> $RT::System )) {
 <h2><&|/l&>Save this search</&></h2>
 <&|/l&>Name:</&> <input name="NewSearchName" value="<%$Name||''%>">
-<&|/l&>Privacy:</&> <& SelectSearchPrivacy, Name => 'SearchPrivacy',
-	Default => $Privacy &><br />
+<&|/l&>Privacy:</&> <& SelectSearchPrivacy, Name => 'SearchPrivacy', Default => $Privacy &><br />
 %     if ($CurrentSearch && $CurrentSearch ne 'new') {
 <input value="<%loc('Update')%>" name="Update" type="submit" /> 
 <input value="<%loc('Save new')%>" name="Save" type="submit" /> 
diff --git a/share/html/Articles/Article/Search.html b/share/html/Articles/Article/Search.html
index 472a3e0..5f9dbdd 100644
--- a/share/html/Articles/Article/Search.html
+++ b/share/html/Articles/Article/Search.html
@@ -146,26 +146,26 @@ if ($CurrentSearch =~ /^(.*-\d+)-SavedSearch-(\d+)$/) {
 
 if ($ARGS{'Load'}) {
     if ($ARGS{'LoadSavedSearch'} =~ /^(.*-\d+)-SavedSearch-(\d+)$/ ) {
-	my $privacy = $1;
-	my $search_id = $2;
-	
-	$search = RT::SavedSearch->new($session{'CurrentUser'});
-	my ($ret, $msg) = $search->Load($privacy, $search_id);
-	if ($ret) {
-	    my $searchargs = $search->GetParameter('args');
-	    # Clean out ARGS and fill it in with the saved args from the 
-	    # loaded search.
-	    foreach my $key (@metakeys) {
-		$searchargs->{$key} = $ARGS{$key};
-	    }
-	    %ARGS = %{$searchargs};
-	    $CurrentSearch = "$privacy-SavedSearch-$search_id";
-	} else {
-	    push(@results, loc("Error: could not load saved search [_1]: [_2]",
-			       $ARGS{'LoadSavedSearch'}, $msg));
-	}
+        my $privacy = $1;
+        my $search_id = $2;
+        
+        $search = RT::SavedSearch->new($session{'CurrentUser'});
+        my ($ret, $msg) = $search->Load($privacy, $search_id);
+        if ($ret) {
+            my $searchargs = $search->GetParameter('args');
+            # Clean out ARGS and fill it in with the saved args from the 
+            # loaded search.
+            foreach my $key (@metakeys) {
+                $searchargs->{$key} = $ARGS{$key};
+            }
+            %ARGS = %{$searchargs};
+            $CurrentSearch = "$privacy-SavedSearch-$search_id";
+        } else {
+            push(@results, loc("Error: could not load saved search [_1]: [_2]",
+                               $ARGS{'LoadSavedSearch'}, $msg));
+        }
     } else {
-	push(@results, loc("Invalid [_1] argument", 'LoadSavedSearch'));
+        push(@results, loc("Invalid [_1] argument", 'LoadSavedSearch'));
     }
 }
 
@@ -174,67 +174,67 @@ if ($ARGS{'Load'}) {
 if ($ARGS{'Save'}) {
     my %searchargs = %ARGS;
     foreach my $key (@metakeys) {
-	delete $searchargs{$key};
+        delete $searchargs{$key};
     }
 
     $search = RT::SavedSearch->new($session{'CurrentUser'});
     unless ($ARGS{'SearchPrivacy'} =~ /^(.*)-(\d+)$/) {
-	# This shouldn't really happen, but hey.
-	push(@results, loc("WARNING: Saving search to user-level privacy"));
-	$ARGS{'SearchPrivacy'} = 'RT::User-'.$session{'CurrentUser'}->Id;
+        # This shouldn't really happen, but hey.
+        push(@results, loc("WARNING: Saving search to user-level privacy"));
+        $ARGS{'SearchPrivacy'} = 'RT::User-'.$session{'CurrentUser'}->Id;
     }
-    my ($ret, $msg) = $search->Save(Privacy => $ARGS{'SearchPrivacy'}, 
-				    Type => 'Article',
-				    Name => $ARGS{'NewSearchName'}, 
-				    SearchParams => {'args' => \%searchargs});
+    my ($ret, $msg) = $search->Save(Privacy => $ARGS{'SearchPrivacy'},
+                                    Type => 'Article',
+                                    Name => $ARGS{'NewSearchName'},
+                                    SearchParams => {'args' => \%searchargs});
     if ($ret) {
-	$CurrentSearch = $ARGS{'SearchPrivacy'} . "-SavedSearch-" . 
-	    $search->Id;
-	push(@results, loc("Created search [_1]", $search->Name));
+        $CurrentSearch = $ARGS{'SearchPrivacy'} . "-SavedSearch-" .
+            $search->Id;
+        push(@results, loc("Created search [_1]", $search->Name));
     } else {
         undef $search; # if we bomb out creating a search
                         # we don't want to have the empty object hang around
-	push(@results, loc("Could not create search: [_1]", $msg));
+        push(@results, loc("Could not create search: [_1]", $msg));
     }
 } elsif ($ARGS{'Update'}) {
     if ($ARGS{'SearchPrivacy'} != $search->Privacy) {
-	push(@results, 
-	     loc("Error: cannot change privacy value of existing search"));
+        push(@results,
+             loc("Error: cannot change privacy value of existing search"));
     } else {
-	my %searchargs = %ARGS;
-	foreach my $key (@metakeys) {
-	    delete $searchargs{$key};
-	}
-	
-	# We already have a search loaded, because CurrentSearch is set,
-	# or else we would not have gotten here.
-	my ($ret, $msg) = $search->Update(Name => $ARGS{'NewSearchName'},
-					  SearchParams => \%searchargs);
-	if ($ret) {
-	    push(@results, loc("Search [_1] updated", $search->Name));
-	} else {
-	    push(@results, loc("Error: search [_1] not updated: [_2]",
-			       $search->Name, $msg));
-	}
+        my %searchargs = %ARGS;
+        foreach my $key (@metakeys) {
+            delete $searchargs{$key};
+        }
+
+        # We already have a search loaded, because CurrentSearch is set,
+        # or else we would not have gotten here.
+        my ($ret, $msg) = $search->Update(Name => $ARGS{'NewSearchName'},
+                                          SearchParams => \%searchargs);
+        if ($ret) {
+            push(@results, loc("Search [_1] updated", $search->Name));
+        } else {
+            push(@results, loc("Error: search [_1] not updated: [_2]",
+                               $search->Name, $msg));
+        }
     }
 } elsif ($ARGS{'Delete'}) {
     # Keep track of this, as we are about to delete the search.
     my $searchname = $search->Name;
     my ($ret, $msg) = $search->Delete;
     if ($ret) {
-	$ARGS{'CurrentSearch'} = undef;
-	push(@results, loc("Deleted search [_1]", $searchname));
-	# Get rid of all the state.
-	foreach my $key (keys %ARGS) {
-	    delete $ARGS{$key};
-	}
-	$CurrentSearch = 'new';
-	$search = undef;
-	$RefersTo = undef;
-	$ReferredToBy = undef;
+        $ARGS{'CurrentSearch'} = undef;
+        push(@results, loc("Deleted search [_1]", $searchname));
+        # Get rid of all the state.
+        foreach my $key (keys %ARGS) {
+            delete $ARGS{$key};
+        }
+        $CurrentSearch = 'new';
+        $search = undef;
+        $RefersTo = undef;
+        $ReferredToBy = undef;
     } else {
-	push(@results, loc("Could not delete search [_1]: [_2]", 
-	     $searchname, $msg));
+        push(@results, loc("Could not delete search [_1]: [_2]",
+             $searchname, $msg));
     }
 }
 
diff --git a/share/html/Dashboards/Modify.html b/share/html/Dashboards/Modify.html
index 02c2f2e..86ba540 100644
--- a/share/html/Dashboards/Modify.html
+++ b/share/html/Dashboards/Modify.html
@@ -124,7 +124,7 @@ else {
 
     if ($id) {
         $title = loc("Modify the dashboard [_1]", $Dashboard->Name);
-    }	
+    }
     # If the create failed
     else {
         $Create = 1;
diff --git a/share/html/Elements/CollectionList b/share/html/Elements/CollectionList
index 2d1817f..4bdff68 100644
--- a/share/html/Elements/CollectionList
+++ b/share/html/Elements/CollectionList
@@ -112,23 +112,23 @@ if ($Class =~ /::/) { # older passed in value
 }
 
 $m->out('<table class="' .
-	($Collection->isa('RT::Tickets') ? 'ticket-list' : 'collection') . ' collection-as-table">');
+            ($Collection->isa('RT::Tickets') ? 'ticket-list' : 'collection') . ' collection-as-table">');
 
 if ( $ShowHeader ) {
   $m->comp('/Elements/CollectionAsTable/Header',
-	   %ARGS,
-	   Class        => $Class,
-	   Format       => \@Format,
-	   FormatString => $Format,
-	   Order        => \@Order,
-	   OrderBy      => \@OrderBy,
-	   Rows         => $Rows,
-	   Page         => $Page,
-	   AllowSorting => $AllowSorting, 
-	   BaseURL      => $BaseURL,
-	   GenericQueryArgs => $GenericQueryArgs,
-	   maxitems     => $maxitems,
-	   );
+           %ARGS,
+           Class        => $Class,
+           Format       => \@Format,
+           FormatString => $Format,
+           Order        => \@Order,
+           OrderBy      => \@OrderBy,
+           Rows         => $Rows,
+           Page         => $Page,
+           AllowSorting => $AllowSorting, 
+           BaseURL      => $BaseURL,
+           GenericQueryArgs => $GenericQueryArgs,
+           maxitems     => $maxitems,
+       );
 }
 
 my ($i, $column_map) = (0, {});
diff --git a/share/html/Elements/CollectionListPaging b/share/html/Elements/CollectionListPaging
index 26c0823..9ca8adb 100644
--- a/share/html/Elements/CollectionListPaging
+++ b/share/html/Elements/CollectionListPaging
@@ -64,15 +64,15 @@ if ($Pages == 1) {
 else{
 $m->out(loc('Page') . ' ');
 my $prev = $m->interp->apply_escapes($m->comp(
-		    '/Elements/QueryString',
-		    %$URLParams,
-		    Page    => ( $CurrentPage - 1 )
-		   ), 'h');
+                    '/Elements/QueryString',
+                    %$URLParams,
+                    Page    => ( $CurrentPage - 1 )
+                   ), 'h');
 my $next = $m->interp->apply_escapes($m->comp(
-		    '/Elements/QueryString',
-		    %$URLParams,
-		    Page    => ( $CurrentPage + 1 )
-		   ), 'h');
+                    '/Elements/QueryString',
+                    %$URLParams,
+                    Page    => ( $CurrentPage + 1 )
+                   ), 'h');
 my %show;
 $show{1} = 1;
 $show{$_} = 1 for (($CurrentPage - 2)..($CurrentPage + 2));
@@ -84,7 +84,7 @@ for my $number ( 1 .. $Pages ) {
         $dots = undef;
         my $qs =
           $m->interp->apply_escapes($m->comp( '/Elements/QueryString', %$URLParams, Page => $number ), 'h');
-	$m->out(qq{<span class="pagenum">});
+        $m->out(qq{<span class="pagenum">});
         if ( $number == $CurrentPage ) {
             $m->out(qq{<span class="currentpage">$number</span> });
         }
@@ -96,7 +96,7 @@ for my $number ( 1 .. $Pages ) {
         $dots = 1;
         $m->out(qq{<span class="dots">...</span>});
     }
-	$m->out(qq{</span>});
+    $m->out(qq{</span>});
 }
 
 if ($CurrentPage > 1) {
diff --git a/share/html/Elements/EditLinks b/share/html/Elements/EditLinks
index 66a8fc6..b74d9fd 100644
--- a/share/html/Elements/EditLinks
+++ b/share/html/Elements/EditLinks
@@ -112,7 +112,7 @@
     <td><i><&|/l&>(Check box to delete)</&></i></td>
   </tr>
 </table>
-			    
+
 </td>
 <td valign="top">
 <h3><&|/l&>New Links</&></h3>
diff --git a/share/html/Elements/HeaderJavascript b/share/html/Elements/HeaderJavascript
index 1a8f34f..1285c53 100644
--- a/share/html/Elements/HeaderJavascript
+++ b/share/html/Elements/HeaderJavascript
@@ -59,7 +59,7 @@ $onload => undef
 <script type="text/javascript" src="<%RT->Config->Get('WebPath')%>/static/RichText/ckeditor.js"></script>
 % }
 <script type="text/javascript"><!--
-	jQuery( loadTitleBoxStates );
+jQuery( loadTitleBoxStates );
 % if ( $focus ) {
     jQuery(function () { focusElementById(<% $focus |n,j%>) });
 % }
diff --git a/share/html/Elements/MessageBox b/share/html/Elements/MessageBox
index 5a17f32..756d1bd 100644
--- a/share/html/Elements/MessageBox
+++ b/share/html/Elements/MessageBox
@@ -62,7 +62,7 @@ if ( $QuoteTransaction ) {
 
 my $signature = '';
 if ( $IncludeSignature and my $text = $session{'CurrentUser'}->UserObj->Signature ) {
-	$signature = "-- \n". $text;
+    $signature = "-- \n". $text;
 }
 
 # wrap="something" seems to really break IE + richtext
diff --git a/share/html/Elements/RT__CustomField/ColumnMap b/share/html/Elements/RT__CustomField/ColumnMap
index c1d12b9..3d74b0d 100644
--- a/share/html/Elements/RT__CustomField/ColumnMap
+++ b/share/html/Elements/RT__CustomField/ColumnMap
@@ -66,7 +66,7 @@ my $COLUMN_MAP = {
     map(
         { my $c = $_; $c => {
             title     => $c, attribute => $c,
-	    value     => sub { return $_[0]->$c() },
+            value     => sub { return $_[0]->$c() },
         } }
         qw(Name Description Type LookupType Pattern)
     ),
@@ -74,21 +74,21 @@ my $COLUMN_MAP = {
         { my $c = $_; my $short = $c; $short =~ s/^Friendly//;
           $c => {
             title     => $short, attribute => $short,
-	    value     => sub { return $_[0]->$c() },
+            value     => sub { return $_[0]->$c() },
         } }
         qw(FriendlyLookupType FriendlyType FriendlyPattern)
     ),
     MaxValues => {
         title     => 'MaxValues', # loc
-	attribute => 'MaxValues',
-	value     => sub {
+        attribute => 'MaxValues',
+        value     => sub {
             my $v = $_[0]->MaxValues;
             return !$v ? $_[0]->loc('unlimited') : $v == 0 ? $_[0]->loc('one') : $v;
         },
     },
     AddedTo => {
         title     => 'Added', # loc
-	value     => sub {
+        value     => sub {
             if ( $_[0]->IsGlobal ) {
                 return $_[0]->loc('Global');
             }
diff --git a/share/html/Elements/RT__Group/ColumnMap b/share/html/Elements/RT__Group/ColumnMap
index bfc520b..b53df04 100644
--- a/share/html/Elements/RT__Group/ColumnMap
+++ b/share/html/Elements/RT__Group/ColumnMap
@@ -75,13 +75,13 @@ my $COLUMN_MAP = {
     },
     Name => {
         title     => 'Name', # loc
-	attribute => 'Name',
-	value     => sub { return $_[0]->Name() },
+        attribute => 'Name',
+        value     => sub { return $_[0]->Name() },
     },
     Description => {
         title     => 'Description', # loc
-	attribute => 'Description',
-	value     => sub { return $_[0]->Description() },
+        attribute => 'Description',
+        value     => sub { return $_[0]->Description() },
     },
 };
 
diff --git a/share/html/Elements/RT__Scrip/ColumnMap b/share/html/Elements/RT__Scrip/ColumnMap
index 417c91c..2778b3a 100644
--- a/share/html/Elements/RT__Scrip/ColumnMap
+++ b/share/html/Elements/RT__Scrip/ColumnMap
@@ -90,8 +90,8 @@ my $COLUMN_MAP = {
     },
     Description => {
         title     => 'Description', # loc
-	attribute => 'Description',
-	value     => sub { return $_[0]->Description() },
+        attribute => 'Description',
+        value     => sub { return $_[0]->Description() },
     },
     Disabled => {
         title     => \' ',
diff --git a/share/html/Elements/RT__Template/ColumnMap b/share/html/Elements/RT__Template/ColumnMap
index 0f09a7e..8e2583e 100644
--- a/share/html/Elements/RT__Template/ColumnMap
+++ b/share/html/Elements/RT__Template/ColumnMap
@@ -59,13 +59,13 @@ my $COLUMN_MAP = {
     },
     Name => {
         title     => 'Name', # loc
-	attribute => 'Name',
-	value     => sub { return $_[0]->Name() },
+        attribute => 'Name',
+        value     => sub { return $_[0]->Name() },
     },
     Description => {
         title     => 'Description', # loc
-	attribute => 'Description',
-	value     => sub { return $_[0]->Description() },
+        attribute => 'Description',
+        value     => sub { return $_[0]->Description() },
     },
     Queue => {
         title     => 'Queue', # loc
diff --git a/share/html/Elements/SelectBoolean b/share/html/Elements/SelectBoolean
index 2de1024..c620714 100644
--- a/share/html/Elements/SelectBoolean
+++ b/share/html/Elements/SelectBoolean
@@ -63,9 +63,9 @@ $False => loc("isn't")
 my $TrueDefault  = '';
 my $FalseDefault = '';
 if ($Default && $Default !~ /true/i) {
-	$FalseDefault = 'selected="selected"';
+    $FalseDefault = 'selected="selected"';
 }
 else {
-	$TrueDefault = 'selected="selected"';
+    $TrueDefault = 'selected="selected"';
 }
 </%INIT>
diff --git a/share/html/Elements/SelectDate b/share/html/Elements/SelectDate
index 18b42ad..f81af86 100644
--- a/share/html/Elements/SelectDate
+++ b/share/html/Elements/SelectDate
@@ -49,18 +49,17 @@
 <input type="text" class="ui-datepicker<% $ShowTime ? ' withtime' : '' %>" id="<% $Name %>" name="<% $Name %>" value="<% $Value %>" size="<% $Size %>" />
 % $m->callback( %ARGS, Name => $Name, CallbackName => 'AfterDateInput' );
 <%init>
-unless ((defined $Default) or 
-	($current <= 0)) {
-	my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) =
-                                            localtime($current);
-        $Default = sprintf("%04d-%02d-%02d %02d:%02d",                         
-                           $year+1900,$mon+1,$mday,                            
-                           $hour,$min);   
+unless ((defined $Default) or ($current <= 0)) {
+    my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) =
+                                           localtime($current);
+    $Default = sprintf("%04d-%02d-%02d %02d:%02d",
+                       $year+1900,$mon+1,$mday,
+                       $hour,$min);
 }
 $Value = $Value || $Default;
 
 unless ($Name) {
-	$Name = $menu_prefix. "_Date";
+    $Name = $menu_prefix. "_Date";
 }
 </%init>
 
diff --git a/share/html/Elements/SelectDateRelation b/share/html/Elements/SelectDateRelation
index 654806e..20b0e66 100644
--- a/share/html/Elements/SelectDateRelation
+++ b/share/html/Elements/SelectDateRelation
@@ -55,6 +55,6 @@
 $Name => undef
 $Default => undef
 $Before => loc('before')
-$On => 	loc('on')
+$On => loc('on')
 $After => loc('after')
 </%ARGS>
diff --git a/share/html/Elements/SelectMatch b/share/html/Elements/SelectMatch
index 692b0ef..9341612 100644
--- a/share/html/Elements/SelectMatch
+++ b/share/html/Elements/SelectMatch
@@ -68,15 +68,15 @@ my $LikeDefault='';
 my $NotLikeDefault ='';
 
 if ($Default && $Default =~ /false|!=/i) {
-	$FalseDefault = qq[ selected="selected"];
+    $FalseDefault = qq[ selected="selected"];
 }
 elsif ($Default && $Default =~ /true|=/i) {
-	$TrueDefault = qq[ selected="selected"];
-} 
+    $TrueDefault = qq[ selected="selected"];
+}
 elsif ($Default && $Default =~ /notlike|NOT LIKE/i) {
-	$NotLikeDefault = qq[ selected="selected"];
+    $NotLikeDefault = qq[ selected="selected"];
 }
 else {
-	$LikeDefault = qq[ selected="selected"];
+    $LikeDefault = qq[ selected="selected"];
 }
 </%INIT>
diff --git a/share/html/Elements/TicketList b/share/html/Elements/TicketList
index 66253ae..740a16d 100644
--- a/share/html/Elements/TicketList
+++ b/share/html/Elements/TicketList
@@ -47,10 +47,10 @@
 %# END BPS TAGGED BLOCK }}}
 <%INIT>
 $m->comp(
-	 '/Elements/CollectionList',
-	 %ARGS,
-	 Class => 'RT::Tickets'
-	);
+         '/Elements/CollectionList',
+         %ARGS,
+         Class => 'RT::Tickets'
+        );
 </%INIT>
 <%ARGS>
 $Collection => undef
diff --git a/share/html/NoAuth/css/aileron/msie6.css b/share/html/NoAuth/css/aileron/msie6.css
index b15ac19..565a995 100644
--- a/share/html/NoAuth/css/aileron/msie6.css
+++ b/share/html/NoAuth/css/aileron/msie6.css
@@ -78,7 +78,7 @@ div#body {
 
 
 .sf-sub-indicator {
-	background:		url(<%RT->Config->Get('WebPath')%>/static/css/images/arrows-ffffff.gif) no-repeat -10px -100px;
+    background: url(<%RT->Config->Get('WebPath')%>/static/css/images/arrows-ffffff.gif) no-repeat -10px -100px;
 }
 
 #page-navigation ul {
diff --git a/share/html/NoAuth/css/base/articles.css b/share/html/NoAuth/css/base/articles.css
index 7c538b2..9c0e0d8 100644
--- a/share/html/NoAuth/css/base/articles.css
+++ b/share/html/NoAuth/css/base/articles.css
@@ -50,5 +50,5 @@
 }
 
 .articles-select-article select {
-	max-width: 20em;
+    max-width: 20em;
 }
diff --git a/share/html/NoAuth/js/jquery-ui-patch-datepicker.js b/share/html/NoAuth/js/jquery-ui-patch-datepicker.js
index 2ac101f..10f8578 100644
--- a/share/html/NoAuth/js/jquery-ui-patch-datepicker.js
+++ b/share/html/NoAuth/js/jquery-ui-patch-datepicker.js
@@ -83,8 +83,8 @@
     $.timepicker._newInst = function($input, o) {
         var tp_inst = $.timepicker._newInst_orig($input, o);
         tp_inst._defaults.onClose = function(dateText, dp_inst) {
-	    if ($.isFunction(o.onClose))
-		o.onClose.call($input[0], dateText, dp_inst, tp_inst);
+            if ($.isFunction(o.onClose))
+                o.onClose.call($input[0], dateText, dp_inst, tp_inst);
         };
         return tp_inst;
     };
diff --git a/share/html/Prefs/Quicksearch.html b/share/html/Prefs/Quicksearch.html
index c189dff..fe72e8b 100644
--- a/share/html/Prefs/Quicksearch.html
+++ b/share/html/Prefs/Quicksearch.html
@@ -78,10 +78,10 @@ my @queues = grep {$_->CurrentUserHasRight('ShowTicket')} @{$Queues->ItemsArrayR
 if ($ARGS{'Save'}) {
     for my $queue (@queues) {
         if ($ARGS{"Want-".$queue->Name}) {
-	    delete $unwanted->{$queue->Name};
-	}
+            delete $unwanted->{$queue->Name};
+        }
         else {
-	    ++$unwanted->{$queue->Name};
+            ++$unwanted->{$queue->Name};
         }
     }
 
diff --git a/share/html/Prefs/Search.html b/share/html/Prefs/Search.html
index bc52fe7..1798b04 100644
--- a/share/html/Prefs/Search.html
+++ b/share/html/Prefs/Search.html
@@ -53,8 +53,8 @@
 <p>
   <&|/l&>You can also edit the predefined search itself</&>:
   <a href="<% RT->Config->Get('WebPath').'/Search/Build.html?'.
-	  $m->comp('/Elements/QueryString',
-		   SavedSearchLoad => 'RT::System-1-SavedSearch-'.$id) %>"><% $search->Name %></a>
+          $m->comp('/Elements/QueryString',
+                   SavedSearchLoad => 'RT::System-1-SavedSearch-'.$id) %>"><% $search->Name %></a>
 </p>
 % }
 
diff --git a/share/html/REST/1.0/Forms/ticket/attachments b/share/html/REST/1.0/Forms/ticket/attachments
index 43b8ed8..a01550a 100644
--- a/share/html/REST/1.0/Forms/ticket/attachments
+++ b/share/html/REST/1.0/Forms/ticket/attachments
@@ -89,23 +89,23 @@ if ($aid) {
             $r->content_type($attachment->ContentType);
         }
     } else {
-	my @data;
-	push @data, [ id    => $attachment->Id   ];
-	push @data, [ Subject    => $attachment->Subject   ];
-	push @data, [ Creator    => $attachment->Creator   ];
-	push @data, [ Created    => $attachment->Created   ];
-	push @data, [ Transaction    => $attachment->TransactionId   ];
-	push @data, [ Parent    => $attachment->Parent   ];
-	push @data, [ MessageId    => $attachment->MessageId   ];
-	push @data, [ Filename    => $attachment->Filename   ];
-	push @data, [ ContentType    => $attachment->ContentType   ];
-	push @data, [ ContentEncoding    => $attachment->ContentEncoding   ];
-	push @data, [ Headers    => $attachment->Headers   ];
-	push @data, [ Content    => $attachment->Content   ];
+        my @data;
+        push @data, [ id    => $attachment->Id   ];
+        push @data, [ Subject    => $attachment->Subject   ];
+        push @data, [ Creator    => $attachment->Creator   ];
+        push @data, [ Created    => $attachment->Created   ];
+        push @data, [ Transaction    => $attachment->TransactionId   ];
+        push @data, [ Parent    => $attachment->Parent   ];
+        push @data, [ MessageId    => $attachment->MessageId   ];
+        push @data, [ Filename    => $attachment->Filename   ];
+        push @data, [ ContentType    => $attachment->ContentType   ];
+        push @data, [ ContentEncoding    => $attachment->ContentEncoding   ];
+        push @data, [ Headers    => $attachment->Headers   ];
+        push @data, [ Content    => $attachment->Content   ];
 
-	my %k = map {@$_} @data;
-	$o = [ map {$_->[0]} @data ];
-	$k = \%k;
+        my %k = map {@$_} @data;
+        $o = [ map {$_->[0]} @data ];
+        $k = \%k;
     }
 
 }
diff --git a/share/html/REST/1.0/Forms/ticket/default b/share/html/REST/1.0/Forms/ticket/default
index ea420cb..9151670 100644
--- a/share/html/REST/1.0/Forms/ticket/default
+++ b/share/html/REST/1.0/Forms/ticket/default
@@ -213,15 +213,15 @@ if (!keys(%data)) {
     my ($time, $key, $val, @data);
 
     push @data, [ id    => "ticket/".$ticket->Id   ];
-    push @data, [ Queue => $ticket->QueueObj->Name ] 
-	if (!%$fields || exists $fields->{lc 'Queue'});
+    push @data, [ Queue => $ticket->QueueObj->Name ]
+        if (!%$fields || exists $fields->{lc 'Queue'});
     push @data, [ Owner => $ticket->OwnerObj->Name ]
-	if (!%$fields || exists $fields->{lc 'Owner'});
+        if (!%$fields || exists $fields->{lc 'Owner'});
     push @data, [ Creator => $ticket->CreatorObj->Name ]
-	if (!%$fields || exists $fields->{lc 'Creator'});
+        if (!%$fields || exists $fields->{lc 'Creator'});
 
     foreach (qw(Subject Status Priority InitialPriority FinalPriority)) {
-	next unless (!%$fields || (exists $fields->{lc $_}));
+        next unless (!%$fields || (exists $fields->{lc $_}));
         push @data, [$_ => $ticket->$_ ];
     }
 
@@ -232,14 +232,14 @@ if (!keys(%data)) {
 
     $time = RT::Date->new ($session{CurrentUser});
     foreach $key (@dates) {
-	next unless (!%$fields || (exists $fields->{lc $key}));
+        next unless (!%$fields || (exists $fields->{lc $key}));
         $time->Set(Format => 'sql', Value => $ticket->$key);
         push @data, [ $key => $time->AsString ];
     }
 
     $time = RT::Date->new ($session{CurrentUser});
     foreach $key (qw(TimeEstimated TimeWorked TimeLeft)) {
-	next unless (!%$fields || (exists $fields->{lc $key}));
+        next unless (!%$fields || (exists $fields->{lc $key}));
         $val = $ticket->$key || 0;
         $val = "$val minutes" if $val;
         push @data, [ $key => $val ];
diff --git a/share/html/REST/1.0/Forms/ticket/history b/share/html/REST/1.0/Forms/ticket/history
index 8b6e017..8c5fb2d 100644
--- a/share/html/REST/1.0/Forms/ticket/history
+++ b/share/html/REST/1.0/Forms/ticket/history
@@ -101,61 +101,61 @@ if ($type) {
 if ($tid) {
     my @data;
     my $t = RT::Transaction->new($session{CurrentUser});
-    
+
     # this paragraph limits the transaction ID query to transactions on this ticket. 
     # Otherwise you can query any transaction from any ticket, which makes no sense.
     my $Transactions = $ticket->Transactions;
     my $tok=0;
     while (my $T = $Transactions->Next()) {
-    	$tok=1 if ($T->Id == $tid)
+        $tok=1 if ($T->Id == $tid)
     }
     if ($tok) {
-    	$t->Load($tid);
+        $t->Load($tid);
     } else {
-    	return [ "# Transaction $tid is not related to Ticket $id", [], {}, 1 ];
+        return [ "# Transaction $tid is not related to Ticket $id", [], {}, 1 ];
     }
 
     push @data, [ id    => $t->Id   ];
     push @data, [ Ticket    => $t->Ticket   ]
-	if (!%$fields || exists $fields->{lc 'Ticket'});
+        if (!%$fields || exists $fields->{lc 'Ticket'});
     push @data, [ TimeTaken    => $t->TimeTaken   ]
-	if (!%$fields || exists $fields->{lc 'TimeTaken'});
+        if (!%$fields || exists $fields->{lc 'TimeTaken'});
     push @data, [ Type    => $t->Type   ]
-	if (!%$fields || exists $fields->{lc 'Type'});
+        if (!%$fields || exists $fields->{lc 'Type'});
     push @data, [ Field    => $t->Field   ]
-	if (!%$fields || exists $fields->{lc 'Field'});
+        if (!%$fields || exists $fields->{lc 'Field'});
     push @data, [ OldValue    => $t->OldValue   ]
-	if (!%$fields || exists $fields->{lc 'OldValue'});
+        if (!%$fields || exists $fields->{lc 'OldValue'});
     push @data, [ NewValue    => $t->NewValue   ]
-	if (!%$fields || exists $fields->{lc 'NewValue'});
+        if (!%$fields || exists $fields->{lc 'NewValue'});
     push @data, [ Data    => $t->Data   ]
-	if (!%$fields || exists $fields->{lc 'Data'});
+        if (!%$fields || exists $fields->{lc 'Data'});
     push @data, [ Description    => $t->Description   ]
-	if (!%$fields || exists $fields->{lc 'Description'});
+        if (!%$fields || exists $fields->{lc 'Description'});
     push @data, [ Content    => $t->Content   ]
-	if (!%$fields || exists $fields->{lc 'Content'});
+        if (!%$fields || exists $fields->{lc 'Content'});
 
 
-    if (!%$fields || exists $fields->{lc 'Content'}) {    
-	my $creator = RT::User->new($session{CurrentUser});
-	$creator->Load($t->Creator);
-	push @data, [ Creator    => $creator->Name   ];
+    if (!%$fields || exists $fields->{lc 'Content'}) {
+        my $creator = RT::User->new($session{CurrentUser});
+        $creator->Load($t->Creator);
+        push @data, [ Creator    => $creator->Name   ];
     }
     push @data, [ Created    => $t->Created   ]
-	if (!%$fields || exists $fields->{lc 'Created'});
+        if (!%$fields || exists $fields->{lc 'Created'});
 
     if (!%$fields || exists $fields->{lc 'Attachments'}) {
-	my $attachlist;
-	my $attachments = $t->Attachments;
-	while (my $a = $attachments->Next) {
-	    my $size = length($a->Content||'');
-	    if ($size > 1024) { $size  = int($size/102.4)/10 . "k" }
-	    else              { $size .= "b" }
+        my $attachlist;
+        my $attachments = $t->Attachments;
+        while (my $a = $attachments->Next) {
+            my $size = length($a->Content||'');
+            if ($size > 1024) { $size  = int($size/102.4)/10 . "k" }
+            else              { $size .= "b" }
             my $name = (defined $a->Filename and length $a->Filename) ? $a->Filename : "untitled";
             $attachlist .= "\n" . $a->Id.": $name ($size)";
-	}
-	
-	push @data, [Attachments => $attachlist];
+        }
+        
+        push @data, [Attachments => $attachlist];
     }
 
     my %k = map {@$_} @data;
@@ -168,31 +168,31 @@ if ($tid) {
     $format = "l" if (%$fields);
 
     while (my $t = $trans->Next) {
-	my $tid = $t->Id;
-
-	if ($format eq "l") {
-	    $tids .= "," if $tids;
-	    $tids .= $tid;
-	} else {
-	    push @$o, $tid;
-	    $k->{$tid} = $t->Description;
-	}
+        my $tid = $t->Id;
+
+        if ($format eq "l") {
+            $tids .= "," if $tids;
+            $tids .= $tid;
+        } else {
+            push @$o, $tid;
+            $k->{$tid} = $t->Description;
+        }
     }
 
     if ($format eq "l") {
-	my @tid;
-	push @tid, "ticket/$id/history/id/$tids";
-	my $fieldstring;
-	foreach my $key (keys %$fields) {
-	    $fieldstring .= "," if $fieldstring;
-	    $fieldstring .= $key;
-	}
-	my ($content, $forms);
-	$m->subexec("/REST/1.0/show", 
-		    id => \@tid, 
-		    format => $format,
+        my @tid;
+        push @tid, "ticket/$id/history/id/$tids";
+        my $fieldstring;
+        foreach my $key (keys %$fields) {
+            $fieldstring .= "," if $fieldstring;
+            $fieldstring .= $key;
+        }
+        my ($content, $forms);
+        $m->subexec("/REST/1.0/show",
+                    id => \@tid,
+                    format => $format,
                     fields => $fieldstring);
-	return [ $c, $o, $k, $e ];
+        return [ $c, $o, $k, $e ];
     }
 }
 
diff --git a/share/html/REST/1.0/Forms/transaction/default b/share/html/REST/1.0/Forms/transaction/default
index 2e45f67..dfe72fe 100644
--- a/share/html/REST/1.0/Forms/transaction/default
+++ b/share/html/REST/1.0/Forms/transaction/default
@@ -65,54 +65,53 @@ if ($tid) {
     my $t = RT::Transaction->new($session{CurrentUser});
     $t->Load($tid);
     if ($format eq "l") {
-      push @data, [ id    => $t->Id   ];
-      push @data, [ Ticket    => $t->Ticket   ]
-  	    if (!%$fields || exists $fields->{lc 'Ticket'});
-      push @data, [ TimeTaken    => $t->TimeTaken   ]
-  	    if (!%$fields || exists $fields->{lc 'TimeTaken'});
-      push @data, [ Type    => $t->Type   ]
-      	if (!%$fields || exists $fields->{lc 'Type'});
-      push @data, [ Field    => $t->Field   ]
-      	if (!%$fields || exists $fields->{lc 'Field'});
-      push @data, [ OldValue    => $t->OldValue   ]
-      	if (!%$fields || exists $fields->{lc 'OldValue'});
-      push @data, [ NewValue    => $t->NewValue   ]
-      	if (!%$fields || exists $fields->{lc 'NewValue'});
-      push @data, [ Data    => $t->Data   ]
-  	    if (!%$fields || exists $fields->{lc 'Data'});
-      push @data, [ Description    => $t->Description   ]
-  	    if (!%$fields || exists $fields->{lc 'Description'});
-      push @data, [ Content    => $t->Content   ]
-       	if (!%$fields || exists $fields->{lc 'Content'});
-      
-      if (!%$fields || exists $fields->{lc 'Content'}) {    
-	    my $creator = RT::User->new($session{CurrentUser});
-  	    $creator->Load($t->Creator);
-  	    push @data, [ Creator    => $creator->Name   ];
-      }
-      push @data, [ Created    => $t->Created   ]
-  	    if (!%$fields || exists $fields->{lc 'Created'});
-  
-      if (!%$fields || exists $fields->{lc 'Attachments'}) {
-  	    my $attachlist;
-  	    my $attachments = $t->Attachments;
-  	    while (my $a = $attachments->Next) {
-  	      my $size = length($a->Content);
-  	      if ($size > 1024) {
-  	        $size  = int($size/102.4)/10 . "k";
-  	      }
-  	      else {
-  	        $size .= "b";
-  	      }
-              my $name = (defined $a->Filename and length $a->Filename) ? $a->Filename : "untitled";
-              $attachlist .= "\n" . $a->Id.": $name ($size)";
-  	    }
-  	    push @data, [Attachments => $attachlist];
-      }
-      
+        push @data, [ id    => $t->Id   ];
+        push @data, [ Ticket    => $t->Ticket   ]
+            if (!%$fields || exists $fields->{lc 'Ticket'});
+        push @data, [ TimeTaken    => $t->TimeTaken   ]
+            if (!%$fields || exists $fields->{lc 'TimeTaken'});
+        push @data, [ Type    => $t->Type   ]
+            if (!%$fields || exists $fields->{lc 'Type'});
+        push @data, [ Field    => $t->Field   ]
+            if (!%$fields || exists $fields->{lc 'Field'});
+        push @data, [ OldValue    => $t->OldValue   ]
+            if (!%$fields || exists $fields->{lc 'OldValue'});
+        push @data, [ NewValue    => $t->NewValue   ]
+            if (!%$fields || exists $fields->{lc 'NewValue'});
+        push @data, [ Data    => $t->Data   ]
+            if (!%$fields || exists $fields->{lc 'Data'});
+        push @data, [ Description    => $t->Description   ]
+            if (!%$fields || exists $fields->{lc 'Description'});
+        push @data, [ Content    => $t->Content   ]
+            if (!%$fields || exists $fields->{lc 'Content'});
+
+        if (!%$fields || exists $fields->{lc 'Content'}) {
+            my $creator = RT::User->new($session{CurrentUser});
+            $creator->Load($t->Creator);
+            push @data, [ Creator    => $creator->Name   ];
+        }
+        push @data, [ Created    => $t->Created   ]
+            if (!%$fields || exists $fields->{lc 'Created'});
+
+        if (!%$fields || exists $fields->{lc 'Attachments'}) {
+            my $attachlist;
+            my $attachments = $t->Attachments;
+            while (my $a = $attachments->Next) {
+                my $size = length($a->Content);
+                if ($size > 1024) {
+                    $size  = int($size/102.4)/10 . "k";
+                }
+                else {
+                    $size .= "b";
+                }
+                my $name = (defined $a->Filename and length $a->Filename) ? $a->Filename : "untitled";
+                $attachlist .= "\n" . $a->Id.": $name ($size)";
+            }
+            push @data, [Attachments => $attachlist];
+        }
     } else {
-      push @data, [ id    => $t->Id   ];
-      push @data, [ Description    => $t->Description   ];
+        push @data, [ id    => $t->Id   ];
+        push @data, [ Description    => $t->Description   ];
     }
 
     my %k = map {@$_} @data;
@@ -125,14 +124,14 @@ if ($tid) {
 #    $format = "l" if (%$fields);
 #
 #    while (my $t = $trans->Next) {
-#	    my $tid = $t->Id;
-#	    if ($format eq "l") {
-#	      $tids .= "," if $tids;
-#	      $tids .= $tid;
-#	    } else {
-#	      push @$o, $tid;
-#	      $k->{$tid} = $t->Description;
-#	    }
+#           my $tid = $t->Id;
+#           if ($format eq "l") {
+#             $tids .= "," if $tids;
+#             $tids .= $tid;
+#           } else {
+#             push @$o, $tid;
+#             $k->{$tid} = $t->Description;
+#           }
 #    }
 #}
 
diff --git a/share/html/REST/1.0/dhandler b/share/html/REST/1.0/dhandler
index 0c9207e..9191695 100644
--- a/share/html/REST/1.0/dhandler
+++ b/share/html/REST/1.0/dhandler
@@ -100,22 +100,22 @@ if ($object eq 'show' ||                                # $REST/show
         if (my ($type, $oids, $extra) =
             ($id =~ m#^($name)/($list|$labels)(?:(/.*))?$#o))
         {
-	    $extra ||= '';
-	    my ($attr, $args) = $extra =~ m{^(?:/($name)(?:/(.*))?)?$}o;
-	    my $tids;
-	    if ($attr and $attr eq 'history' and $args) {
-	       	($tids) = $args =~ m#id/(\d.*)#o;
-	    }
-	    # expand transaction and attachment range specifications
-	    # (if applicable)
-	    foreach my $oid (expand_list($oids)) {
-		if ($tids) {
-		    push(@objects, "$type/$oid/$attr/id/$_") for expand_list($tids);
-		} else {
-		    push(@objects, "$type/$oid$extra");
-		}
-	    }
-	}
+            $extra ||= '';
+            my ($attr, $args) = $extra =~ m{^(?:/($name)(?:/(.*))?)?$}o;
+            my $tids;
+            if ($attr and $attr eq 'history' and $args) {
+                ($tids) = $args =~ m#id/(\d.*)#o;
+            }
+            # expand transaction and attachment range specifications
+            # (if applicable)
+            foreach my $oid (expand_list($oids)) {
+                if ($tids) {
+                    push(@objects, "$type/$oid/$attr/id/$_") for expand_list($tids);
+                } else {
+                    push(@objects, "$type/$oid$extra");
+                }
+            }
+        }
         else {
             $status = "400 Bad Request";
             $output = "Invalid object ID specified: '$id'";
diff --git a/share/html/REST/1.0/search/ticket b/share/html/REST/1.0/search/ticket
index 16c6c6a..cf9e8a7 100644
--- a/share/html/REST/1.0/search/ticket
+++ b/share/html/REST/1.0/search/ticket
@@ -123,32 +123,32 @@ my @output;
 while (my $ticket = $tickets->Next) {
     $n++;
 
-	my $id = $ticket->Id;
+    my $id = $ticket->Id;
     if ($format eq "i") {
         $output .= "ticket/" . $id . "\n";
     }
     elsif ($format eq "s") {
-	if ($fields) {
-        	my $result = $m->comp("/REST/1.0/Forms/ticket/default", id => $id, format => $format, fields => \%fields);
-		my ($notes, $order, $key_values, $errors) = @$result;
-		# If it's the first time through, add our header
-		if ($n == 1) {
-			$output .= join("\t",@$order)."\n";
-		}
-		# Cut off the annoying ticket/ before the id;
-		$key_values->{'id'} = $id;
-		$output .= join("\t", map { ref $key_values->{$_} eq 'ARRAY' ?
-join( ', ', @{$key_values->{$_}} ) : $key_values->{$_} } @$order)."\n";
-
-
-	} else {
-        	$output .= $ticket->Id . ": ". $ticket->Subject . "\n";
-	}
+        if ($fields) {
+            my $result = $m->comp("/REST/1.0/Forms/ticket/default", id => $id, format => $format, fields => \%fields);
+            my ($notes, $order, $key_values, $errors) = @$result;
+            # If it's the first time through, add our header
+            if ($n == 1) {
+                $output .= join("\t",@$order)."\n";
+            }
+            # Cut off the annoying ticket/ before the id;
+            $key_values->{'id'} = $id;
+            $output .= join("\t", map {
+                ref $key_values->{$_} eq 'ARRAY'
+                    ? join( ', ', @{$key_values->{$_}} )
+                    : $key_values->{$_} } @$order)."\n";
+        } else {
+            $output .= $ticket->Id . ": ". $ticket->Subject . "\n";
+        }
     }
     else {
         my $d = $m->comp("/REST/1.0/Forms/ticket/default", id => $id, format => $format, fields => \%fields);
         my ($c, $o, $k, $e) = @$d;
-	push @output, [ $c, $o, $k ];
+        push @output, [ $c, $o, $k ];
     }
 }
 if ($n == 0 && $format ne "i") {
diff --git a/share/html/Search/Elements/BuildFormatString b/share/html/Search/Elements/BuildFormatString
index 15829fd..3a3e924 100644
--- a/share/html/Search/Elements/BuildFormatString
+++ b/share/html/Search/Elements/BuildFormatString
@@ -230,7 +230,7 @@ foreach my $field (@seen) {
     my $row = "'";
     $row .= $field->{'Prefix'} if defined $field->{'Prefix'};
     $row .= "__" . ($field->{'Column'} =~ m/\(/ ? $field->{'Column'} # func, don't escape
-		    : $m->interp->apply_escapes( $field->{'Column'}, 'h' )) . "__"
+                        : $m->interp->apply_escapes( $field->{'Column'}, 'h' )) . "__"
       unless ( $field->{'Column'} eq "<blank>" );
     $row .= $field->{'Suffix'} if defined $field->{'Suffix'};
     $row .= "'";
diff --git a/share/html/Search/Elements/PickBasics b/share/html/Search/Elements/PickBasics
index 80b5349..a45d264 100644
--- a/share/html/Search/Elements/PickBasics
+++ b/share/html/Search/Elements/PickBasics
@@ -70,10 +70,10 @@ my @lines = (
             Type => 'component',
             Path => '/Elements/SelectBoolean',
             Arguments => {
-			    True => loc("matches"), 
-			    False => loc("doesn't match"), 
-			    TrueVal => 'LIKE',
-			    FalseVal => 'NOT LIKE',
+                True => loc("matches"), 
+                False => loc("doesn't match"), 
+                TrueVal => 'LIKE',
+                FalseVal => 'NOT LIKE',
             },
         },
         Value => { Type => 'text', Size => 20 },
diff --git a/share/html/Search/Elements/SearchesForObject b/share/html/Search/Elements/SearchesForObject
index efbf220..d61554d 100644
--- a/share/html/Search/Elements/SearchesForObject
+++ b/share/html/Search/Elements/SearchesForObject
@@ -55,10 +55,10 @@ my @result;
 while (my $search = $Object->Attributes->Next) {
     my $desc;
     if ($search->Name eq 'SavedSearch') {
-	push @result, [$search->Description, $search];
+        push @result, [$search->Description, $search];
     }
     elsif ($search->Name =~ m/^Search - (.*)/) {
-	push @result, [$1, $search];
+        push @result, [$1, $search];
     }
 }
 return @result;
diff --git a/share/html/Search/Elements/SelectLinks b/share/html/Search/Elements/SelectLinks
index 0b7ce12..a51e776 100644
--- a/share/html/Search/Elements/SelectLinks
+++ b/share/html/Search/Elements/SelectLinks
@@ -56,11 +56,11 @@ $Name => 'LinksField'
 
 <%INIT>
 my @fields = ('HasMember',
-	      'MemberOf',
-	      'DependsOn',
-	      'DependedOnBy',
-	      'RefersTo',
-	      'ReferredToBy',
-	      'LinkedTo',
-	      );
+              'MemberOf',
+              'DependsOn',
+              'DependedOnBy',
+              'RefersTo',
+              'ReferredToBy',
+              'LinkedTo',
+              );
 </%INIT>
diff --git a/share/html/Search/Results.html b/share/html/Search/Results.html
index 17f4f0e..a36cc2e 100644
--- a/share/html/Search/Results.html
+++ b/share/html/Search/Results.html
@@ -150,7 +150,7 @@ my $QueryString = "?".$m->comp('/Elements/QueryString',
 my $ShortQueryString = "?".$m->comp('/Elements/QueryString', Query => $Query);
 
 if ($ARGS{'TicketsRefreshInterval'}) {
-	$session{'tickets_refresh_interval'} = $ARGS{'TicketsRefreshInterval'};
+    $session{'tickets_refresh_interval'} = $ARGS{'TicketsRefreshInterval'};
 }
 
 my $refresh = $session{'tickets_refresh_interval'}
diff --git a/share/html/SelfService/Closed.html b/share/html/SelfService/Closed.html
index 6fd6e83..126dc30 100644
--- a/share/html/SelfService/Closed.html
+++ b/share/html/SelfService/Closed.html
@@ -51,8 +51,8 @@
     %ARGS,
     status          => [ RT::Queue->InactiveStatusArray ],
     friendly_status => loc('closed'), 
-	BaseURL         => RT->Config->Get('WebPath') ."/SelfService/Closed.html?",
-	Page            => $Page,
+    BaseURL         => RT->Config->Get('WebPath') ."/SelfService/Closed.html?",
+    Page            => $Page,
 &>
 
 <%ARGS>
diff --git a/share/html/SelfService/Elements/MyRequests b/share/html/SelfService/Elements/MyRequests
index 76accfc..c4f10f6 100644
--- a/share/html/SelfService/Elements/MyRequests
+++ b/share/html/SelfService/Elements/MyRequests
@@ -47,15 +47,15 @@
 %# END BPS TAGGED BLOCK }}}
 <&| /Widgets/TitleBox, title => $title &>
 <& /Elements/CollectionList, Title   => $title,
-			 Format  => $Format, 
-			 Query   => $Query, 
-			 Order   => @Order, 
-			 OrderBy => @OrderBy,
-			 BaseURL => $BaseURL,
-			 AllowSorting => 1,
-			 Class   => 'RT::Tickets',
-             Rows    => $Rows,
-			 Page    => $Page &>
+  Format  => $Format,
+  Query   => $Query,
+  Order   => @Order,
+  OrderBy => @OrderBy,
+  BaseURL => $BaseURL,
+  AllowSorting => 1,
+  Class   => 'RT::Tickets',
+  Rows    => $Rows,
+  Page    => $Page &>
 </&>
 
 <%INIT>
diff --git a/share/html/SelfService/Prefs.html b/share/html/SelfService/Prefs.html
index ac5d725..34e9162 100644
--- a/share/html/SelfService/Prefs.html
+++ b/share/html/SelfService/Prefs.html
@@ -59,7 +59,7 @@
 
 <br />
 <& /Elements/Submit, Label => loc('Save Changes') &>
-	  </form>
+</form>
 
 
 <%INIT>
@@ -79,8 +79,8 @@ if (defined $NewPass1 && length $NewPass1 ) {
 if ($Signature) {
     $Signature =~ s/(\r\n|\r)/\n/g;
     if ($Signature ne $user->Signature) {
-	my ($val, $msg) = $user->SetSignature($Signature);
-	push (@results, "Signature: ".$msg);
+        my ($val, $msg) = $user->SetSignature($Signature);
+        push (@results, "Signature: ".$msg);
     }
 }
 
diff --git a/share/html/Ticket/Attachment/dhandler b/share/html/Ticket/Attachment/dhandler
index 86c99e1..25cb1e7 100644
--- a/share/html/Ticket/Attachment/dhandler
+++ b/share/html/Ticket/Attachment/dhandler
@@ -83,7 +83,7 @@
      require MIME::Types;
      my $mimetype = MIME::Types->new->type($content_type);
      unless ( $mimetype && $mimetype->isBinary ) {
-	    $content_type .= ";charset=$iana";
+         $content_type .= ";charset=$iana";
      }
 
      $r->content_type( $content_type );
diff --git a/share/html/Ticket/Create.html b/share/html/Ticket/Create.html
index 4f9ebc4..f0be393 100644
--- a/share/html/Ticket/Create.html
+++ b/share/html/Ticket/Create.html
@@ -218,9 +218,9 @@
 <tr>
 <td width="50%" valign="top" class="boxcontainer">
     <div class="ticket-info-basics">
-	  <&| /Widgets/TitleBox, title => loc('The Basics'), 
-		title_class=> 'inverse',  
-		color => "#993333" &>
+          <&| /Widgets/TitleBox, title => loc('The Basics'), 
+                title_class=> 'inverse',  
+                color => "#993333" &>
 <table border="0">
 <tr><td class="label"><&|/l&>Priority</&>:</td>
 <td><& /Elements/SelectPriority,
@@ -251,8 +251,8 @@
 <br />
 <div class="ticket-info-dates">
 <&|/Widgets/TitleBox, title => loc("Dates"),
-		title_class=> 'inverse',  
-		 color => "#663366" &>
+  title_class=> 'inverse',  
+  color => "#663366" &>
 
 <table>
 <tr><td class="label"><&|/l&>Starts</&>:</td><td><& /Elements/SelectDate, Name => "Starts", Default => $ARGS{Starts} || '' &></td></tr>
@@ -391,7 +391,7 @@ my $ticket = RT::Ticket->new($session{'CurrentUser'}); # empty ticket object
 # deal with deleting uploaded attachments
 foreach my $key (keys %ARGS) {
     if ($key =~ m/^DeleteAttach-(.+)$/) {
-	delete $session{'Attachments'}{$1};
+        delete $session{'Attachments'}{$1};
     }
     $session{'Attachments'} = { %{$session{'Attachments'} || {}} };
 }
@@ -405,7 +405,7 @@ if ( defined $ARGS{'Attach'} && length $ARGS{'Attach'} ) { # attachment?
     my $file_path = Encode::decode_utf8("$ARGS{'Attach'}");
     $session{'Attachments'} = {
         %{$session{'Attachments'} || {}},
-	$file_path => $attachment,
+        $file_path => $attachment,
     };
 }
 
diff --git a/share/html/Ticket/Elements/EditPeople b/share/html/Ticket/Elements/EditPeople
index 877cbd9..140fae9 100644
--- a/share/html/Ticket/Elements/EditPeople
+++ b/share/html/Ticket/Elements/EditPeople
@@ -60,8 +60,8 @@
 
 <& AddWatchers, Ticket => $Ticket, UserString => $UserString,
         UserOp => $UserOp, UserField => $UserField,
-	GroupString => $GroupString, GroupOp => $GroupOp,
-	GroupField => $GroupField, PrivilegedOnly => $PrivilegedOnly &> 
+        GroupString => $GroupString, GroupOp => $GroupOp,
+        GroupField => $GroupField, PrivilegedOnly => $PrivilegedOnly &> 
 </td><td valign="top">
 <h3><&|/l&>Owner</&></h3>
 <&|/l&>Owner</&>: <& /Elements/SelectOwner, Name => 'Owner', QueueObj => $Ticket->QueueObj, TicketObj => $Ticket, Default => $Ticket->OwnerObj->Id, DefaultValue => 0&>
diff --git a/share/html/Tools/Offline.html b/share/html/Tools/Offline.html
index b7cae7c..84d88d3 100644
--- a/share/html/Tools/Offline.html
+++ b/share/html/Tools/Offline.html
@@ -52,8 +52,7 @@
 
 % $m->callback( Requestor => \$requestoraddress, Queue => \$qname, %ARGS );
 
-<form action="Offline.html" name="TicketUpdate" 
-	method="post" enctype="multipart/form-data">
+<form action="Offline.html" name="TicketUpdate" method="post" enctype="multipart/form-data">
 <table>
 <tr>
 <td class="label">
@@ -111,7 +110,7 @@ if ($ARGS{'Parse'} && $ARGS{'Template'}) {
 
     my ($buffer, $template);
     while ( my $bytesread = read( $fh, $buffer, 4096 ) ) {
-	    $template .= $buffer;
+        $template .= $buffer;
     }
     my $encode = RT::I18N::_GuessCharset( $template );
     require Encode;
@@ -138,29 +137,29 @@ if ($ARGS{'Parse'} && $ARGS{'Template'}) {
     push @results, $action->UpdateByTemplate();
 } else {
     if ($ARGS{'Query'}) {
-	my $Tickets = RT::Tickets->new($session{'CurrentUser'});
-	$Tickets->FromSQL($ARGS{'Query'});
-	
-	while (my $t = $Tickets->Next) {
-	    $string .= "===Update-Ticket: " . $t->Id . "\n";
-	    $string .= $action->GetUpdateTemplate($t);
-	    $string .= "" . "\n";
-	}
-	
-	$string .= "" . "\n";
-	$string .= "===# DO NOT EDIT BELOW THIS LINE#===\n";
-	$string .= "" . "\n";
-	
-	while (my $t = $Tickets->Next) {
-	    $string .= "===# DO NOT EDIT #===\n";
-		$string .= "===Base-Ticket: " . $t->Id . "\n";
-	    $string .= $action->GetBaseTemplate($t);
-	    $string .= "===# DO NOT EDIT #===\n";
-		$string .= "" . "\n";
-	}
+        my $Tickets = RT::Tickets->new($session{'CurrentUser'});
+        $Tickets->FromSQL($ARGS{'Query'});
+
+        while (my $t = $Tickets->Next) {
+            $string .= "===Update-Ticket: " . $t->Id . "\n";
+            $string .= $action->GetUpdateTemplate($t);
+            $string .= "" . "\n";
+        }
+
+        $string .= "" . "\n";
+        $string .= "===# DO NOT EDIT BELOW THIS LINE#===\n";
+        $string .= "" . "\n";
+
+        while (my $t = $Tickets->Next) {
+            $string .= "===# DO NOT EDIT #===\n";
+                $string .= "===Base-Ticket: " . $t->Id . "\n";
+            $string .= $action->GetBaseTemplate($t);
+            $string .= "===# DO NOT EDIT #===\n";
+                $string .= "" . "\n";
+        }
     } else {
-	$string .= "===Create-Ticket: ticket1\n";
-	$string .= $action->GetCreateTemplate();
+        $string .= "===Create-Ticket: ticket1\n";
+        $string .= $action->GetCreateTemplate();
     }
 }
 </%INIT>
diff --git a/share/html/Widgets/SavedSearch b/share/html/Widgets/SavedSearch
index df22dcb..6a4148e 100644
--- a/share/html/Widgets/SavedSearch
+++ b/share/html/Widgets/SavedSearch
@@ -111,7 +111,7 @@ if ( $args->{SavedSearchSave} ) {
         # rename
         $search->SetDescription( $args->{SavedSearchDescription} );
         $search->SetSubValues(%$SearchParams);
-	    push @actions, loc( '[_1] [_2] updated.', loc($self->{SearchType}), $args->{SavedSearchDescription} );
+        push @actions, loc( '[_1] [_2] updated.', loc($self->{SearchType}), $args->{SavedSearchDescription} );
     }
     else {
         # new saved search
@@ -123,7 +123,7 @@ if ( $args->{SavedSearchSave} ) {
             SearchParams => $SearchParams
         );
         if ($ok) {
-	        $self->{CurrentSearch}{Object} = $saved_search->{Attribute};
+            $self->{CurrentSearch}{Object} = $saved_search->{Attribute};
             $self->{SearchId} = $args->{SavedChartSearchId} = 'RT::User-' .
                 $session{CurrentUser}->id . '-SavedSearch-' .
                 $saved_search->Id;
diff --git a/share/html/Widgets/SelectionBox b/share/html/Widgets/SelectionBox
index 979adc9..526b352 100644
--- a/share/html/Widgets/SelectionBox
+++ b/share/html/Widgets/SelectionBox
@@ -54,13 +54,13 @@
 %#
 %# <%init>:
 %# my $sel = $m->comp ('/Widgets/SelectionBox:new',
-%#		  Action => me.html',
-%#		  Name => 'my-selection',
-%#		  Available => \@items,
+%#                Action => me.html',
+%#                Name => 'my-selection',
+%#                Available => \@items,
 %#                # you can do things with @{$sel->{Current}} in the 
 %#                # OnSubmit callback
-%#		  OnSubmit => sub { my $sel = shift; },
-%#		  Selected => \@selected);
+%#                OnSubmit => sub { my $sel = shift; },
+%#                Selected => \@selected);
 %#
 %# $m->comp ('/Widgets/SelectionBox:process', %ARGS, self => $sel)
 %#
diff --git a/share/html/Widgets/TitleBoxStart b/share/html/Widgets/TitleBoxStart
index cbcc5c3..4f43ad2 100644
--- a/share/html/Widgets/TitleBoxStart
+++ b/share/html/Widgets/TitleBoxStart
@@ -54,8 +54,8 @@
             $title_href ? qq[<a href="$title_href">] : '' | n
         %><% $title %><% $title_raw |n %><% $title_href ? "</a>" : '' |n%></span>
     <span class="right<%($titleright_href || $titleright || $titleright_raw) ? '' : '-empty' %>">\
-	<% $titleright_href ? qq[<a href="$titleright_href">] : '' | n %>\
-	<% $titleright  %><% $titleright_raw |n%><% $titleright_href ? "</a>" : '' |n%>\
+        <% $titleright_href ? qq[<a href="$titleright_href">] : '' | n %>\
+        <% $titleright  %><% $titleright_raw |n%><% $titleright_href ? "</a>" : '' |n%>\
     </span>
   </div>
   <div class="titlebox-content <% $bodyclass %><% $rolledup ? " hidden" : ""%>" id="<% $tid %>">
diff --git a/share/html/m/login b/share/html/m/login
index 99585e2..d3993ad 100644
--- a/share/html/m/login
+++ b/share/html/m/login
@@ -105,16 +105,15 @@ unless (!defined($uri->authority) || $uri->authority eq $uri_base_url->authority
 <& /Elements/Submit, Label => loc('Login')&>
 
 % foreach my $key (keys %ARGS) {
-%  if (($key ne 'user') and ($key ne 'pass')) {
-% 	if (ref($ARGS{$key}) =~ /ARRAY/) {
-% 		foreach my $val (@{$ARGS{$key}}) {
+%     if (($key ne 'user') and ($key ne 'pass')) {
+%         if (ref($ARGS{$key}) =~ /ARRAY/) {
+%             foreach my $val (@{$ARGS{$key}}) {
 <input type="hidden" class="hidden" name="<%$key %>" value="<% $val %>" />
-% 		}
-% 	}
-%	else {
+%             }
+%         } else {
 <input type="hidden" class="hidden" name="<% $key %>" value="<% $ARGS{$key} %>" />
-% 	}
-%  }
+%         }
+%     }
 % }
 </form>
 % }
diff --git a/share/html/m/ticket/create b/share/html/m/ticket/create
index f97bb7f..4a77bfb 100644
--- a/share/html/m/ticket/create
+++ b/share/html/m/ticket/create
@@ -150,7 +150,7 @@ $QueueObj->Disabled && Abort(loc("Cannot create tickets in a disabled queue."));
 # deal with deleting uploaded attachments
 foreach my $key (keys %ARGS) {
     if ($key =~ m/^DeleteAttach-(.+)$/) {
-	delete $session{'Attachments'}{$1};
+        delete $session{'Attachments'}{$1};
     }
     $session{'Attachments'} = { %{$session{'Attachments'} || {}} };
 }
@@ -164,7 +164,7 @@ if ( defined $ARGS{'Attach'} && length $ARGS{'Attach'} ) { # attachment?
     my $file_path = Encode::decode_utf8("$ARGS{'Attach'}");
     $session{'Attachments'} = {
         %{$session{'Attachments'} || {}},
-	$file_path => $attachment,
+        $file_path => $attachment,
     };
 }
 
@@ -356,9 +356,9 @@ $showrows->(
 
 
     <div class="ticket-info-basics">
-	  <&| /Widgets/TitleBox, title => loc('The Basics'), 
-		title_class=> 'inverse',  
-		color => "#993333" &>
+          <&| /Widgets/TitleBox, title => loc('The Basics'), 
+                title_class=> 'inverse',  
+                color => "#993333" &>
 <%perl>
 $showrows->(
     loc("Priority") => $m->scomp(
@@ -397,8 +397,8 @@ $showrows->(
 </%perl>
 </&>
 <&|/Widgets/TitleBox, title => loc("Dates"),
-		title_class=> 'inverse',  
-		 color => "#663366"  &>
+    title_class=> 'inverse',  
+    color => "#663366"  &>
 
 <%perl>
 $showrows->(
diff --git a/t/api/cfsearch.t b/t/api/cfsearch.t
index 7a460ce..4df6e0a 100644
--- a/t/api/cfsearch.t
+++ b/t/api/cfsearch.t
@@ -36,9 +36,9 @@ my $cfvalue1 = 'Foo';
 
 {
   my ($id, $msg) = $u1->AddCustomFieldValue(
-			  Field => $cfname,
-			  Value => $cfvalue1,
-			  RecordTransaction => 0 );
+                          Field => $cfname,
+                          Value => $cfvalue1,
+                          RecordTransaction => 0 );
   ok( $id, "Adding CF value '$cfvalue1' - " . $msg );
 }
 
@@ -51,18 +51,18 @@ my $cfvalue1 = 'Foo';
 
 {
   my ($id, $msg) = $u1->DeleteCustomFieldValue(
-			    Field => $cfname,
-			    Value => $cfvalue1,
-			    RecordTransaction => 0 );
+                            Field => $cfname,
+                            Value => $cfvalue1,
+                            RecordTransaction => 0 );
   ok( $id, "Deleting CF value - " . $msg );
 }
 
 my $cfvalue2 = 'Bar';
 {
   my ($id, $msg) = $u1->AddCustomFieldValue(
-			  Field => $cfname,
-			  Value => $cfvalue2,
-			  RecordTransaction => 0 );
+                          Field => $cfname,
+                          Value => $cfvalue2,
+                          RecordTransaction => 0 );
   ok( $id, "Adding second CF value '$cfvalue2' - " . $msg );
 }
 
@@ -92,9 +92,9 @@ sub QueryCFValue{
   isa_ok( $users, 'RT::Users' );
 
   $users->LimitCustomField(
-	  CUSTOMFIELD => $cf_id,
-	  OPERATOR => "=",
-	  VALUE => $cf_value );
+      CUSTOMFIELD => $cf_id,
+      OPERATOR => "=",
+      VALUE => $cf_value );
 
   while ( my $filtered_user = $users->Next() ){
     my $cf_values = $filtered_user->CustomFieldValues($cf->id);
diff --git a/t/api/cron.t b/t/api/cron.t
index 6bd992d..b16adde 100644
--- a/t/api/cron.t
+++ b/t/api/cron.t
@@ -24,10 +24,10 @@ This is a content string with no content.';
 
 my $template_obj = RT::Template->new($CurrentUser);
 $template_obj->Create(Queue       => '0',
-		      Name        => 'recordtest',
-		      Description => 'testing Record actions',
-		      Content     => $template_content,
-		     );
+                      Name        => 'recordtest',
+                      Description => 'testing Record actions',
+                      Content     => $template_content,
+                     );
 
 # Create a queue and some tickets.
 
@@ -36,17 +36,17 @@ my $queue_obj = RT::Queue->new($CurrentUser);
 ok($ret, 'record test queue creation');
 
 my $ticket1 = RT::Ticket->new($CurrentUser);
-my ($id, $tobj, $msg2) = $ticket1->Create(Queue    => $queue_obj,
-					 Requestor => ['tara at example.com'],
-					 Subject   => 'bork bork bork',
-					 Priority  => 22,
-					);
+my ($id, $tobj, $msg2) = $ticket1->Create(Queue     => $queue_obj,
+                                          Requestor => ['tara at example.com'],
+                                          Subject   => 'bork bork bork',
+                                          Priority  => 22,
+                                        );
 ok($id, 'record test ticket creation 1');
 my $ticket2 = RT::Ticket->new($CurrentUser);
 ($id, $tobj, $msg2) = $ticket2->Create(Queue     => $queue_obj,
-				      Requestor => ['root at localhost'],
-				      Subject   => 'hurdy gurdy'
-				      );
+                                       Requestor => ['root at localhost'],
+                                       Subject   => 'hurdy gurdy'
+                                      );
 ok($id, 'record test ticket creation 2');
 
 
@@ -58,7 +58,7 @@ ok(require RT::Search::FromSQL, "Search::FromSQL loaded");
 my $ticketsqlstr = "Requestor.EmailAddress = '" . $CurrentUser->EmailAddress .
     "' AND Priority > '20'";
 my $search = RT::Search::FromSQL->new(Argument => $ticketsqlstr, TicketsObj => RT::Tickets->new($CurrentUser),
-				      );
+                                  );
 is(ref($search), 'RT::Search::FromSQL', "search created");
 ok($search->Prepare(), "fromsql search run");
 my $counter = 0;
diff --git a/t/api/savedsearch.t b/t/api/savedsearch.t
index 0aa67ee..2e924bf 100644
--- a/t/api/savedsearch.t
+++ b/t/api/savedsearch.t
@@ -13,9 +13,9 @@ use Test::Warn;
 
 my $searchuser = RT::User->new(RT->SystemUser);
 my ($ret, $msg) = $searchuser->Create(Name => 'searchuser'.$$,
-		    Privileged => 1,
-		    EmailAddress => "searchuser\@p$$.example.com",
-		    RealName => 'Search user');
+                    Privileged => 1,
+                    EmailAddress => "searchuser\@p$$.example.com",
+                    RealName => 'Search user');
 ok($ret, "created searchuser: $msg");
 $searchuser->PrincipalObj->GrantRight(Right => 'LoadSavedSearch');
 $searchuser->PrincipalObj->GrantRight(Right => 'CreateSavedSearch');
@@ -26,9 +26,9 @@ my $ingroup = RT::Group->new(RT->SystemUser);
 $ingroup->CreateUserDefinedGroup(Name => 'searchgroup1'.$$);
 $ingroup->AddMember($searchuser->Id);
 $searchuser->PrincipalObj->GrantRight(Right => 'EditSavedSearches',
-				      Object => $ingroup);
+                                      Object => $ingroup);
 $searchuser->PrincipalObj->GrantRight(Right => 'ShowSavedSearches',
-				      Object => $ingroup);
+                                      Object => $ingroup);
 
 # This is the group whose searches searchuser should not be able to see.
 my $outgroup = RT::Group->new(RT->SystemUser);
@@ -44,9 +44,9 @@ $searchuser->PrincipalObj->GrantRight(Right => 'OwnTicket', Object => $queue);
 
 my $ticket = RT::Ticket->new(RT->SystemUser);
 $ticket->Create(Queue => $queue->Id,
-		Requestor => [ $searchuser->Name ],
-		Owner => $searchuser,
-		Subject => 'saved search test');
+                Requestor => [ $searchuser->Name ],
+                Owner => $searchuser,
+                Subject => 'saved search test');
 
 
 # Now start the search madness.
@@ -67,41 +67,41 @@ my $format = '\'   <b><a href="/Ticket/Display.html?id=__id__">__id__</a></b>/TI
 
 my $mysearch = RT::SavedSearch->new($curruser);
 ($ret, $msg) = $mysearch->Save(Privacy => 'RT::User-' . $searchuser->Id,
-			       Type => 'Ticket',
-			       Name => 'owned by me',
-			       SearchParams => {'Format' => $format,
-						'Query' => "Owner = '" 
-						    . $searchuser->Name 
-						    . "'"});
+                               Type => 'Ticket',
+                               Name => 'owned by me',
+                               SearchParams => {'Format' => $format,
+                                                'Query' => "Owner = '" 
+                                                    . $searchuser->Name 
+                                                    . "'"});
 ok($ret, "mysearch was created");
 
 
 my $groupsearch = RT::SavedSearch->new($curruser);
 ($ret, $msg) = $groupsearch->Save(Privacy => 'RT::Group-' . $ingroup->Id,
-				  Type => 'Ticket',
-				  Name => 'search queue',
-				  SearchParams => {'Format' => $format,
-						   'Query' => "Queue = '"
-						       . $queue->Name . "'"});
+                                  Type => 'Ticket',
+                                  Name => 'search queue',
+                                  SearchParams => {'Format' => $format,
+                                                   'Query' => "Queue = '"
+                                                       . $queue->Name . "'"});
 ok($ret, "groupsearch was created");
 
 my $othersearch = RT::SavedSearch->new($curruser);
 ($ret, $msg) = $othersearch->Save(Privacy => 'RT::Group-' . $outgroup->Id,
-				  Type => 'Ticket',
-				  Name => 'searchuser requested',
-				  SearchParams => {'Format' => $format,
-						   'Query' => 
-						       "Requestor.Name LIKE 'search'"});
+                                  Type => 'Ticket',
+                                  Name => 'searchuser requested',
+                                  SearchParams => {'Format' => $format,
+                                                   'Query' => 
+                                                       "Requestor.Name LIKE 'search'"});
 ok(!$ret, "othersearch NOT created");
 like($msg, qr/Failed to load object for/, "...for the right reason");
 
 $othersearch = RT::SavedSearch->new(RT->SystemUser);
 ($ret, $msg) = $othersearch->Save(Privacy => 'RT::Group-' . $outgroup->Id,
-				  Type => 'Ticket',
-				  Name => 'searchuser requested',
-				  SearchParams => {'Format' => $format,
-						   'Query' => 
-						       "Requestor.Name LIKE 'search'"});
+                                  Type => 'Ticket',
+                                  Name => 'searchuser requested',
+                                  SearchParams => {'Format' => $format,
+                                                   'Query' => 
+                                                       "Requestor.Name LIKE 'search'"});
 ok($ret, "othersearch created by systemuser");
 
 # Now try to load some searches.
@@ -148,8 +148,8 @@ warning_like {
 isnt($loadedsearch4->Id, $othersearch->Id, "Did not load othersearch");
 
 # Try to update an existing search.
-$loadedsearch1->Update(	SearchParams => {'Format' => $format,
-			'Query' => "Queue = '" . $queue->Name . "'" } );
+$loadedsearch1->Update( SearchParams => {'Format' => $format,
+                        'Query' => "Queue = '" . $queue->Name . "'" } );
 like($loadedsearch1->GetParameter('Query'), qr/Queue/,
      "Updated mysearch parameter");
 is($loadedsearch1->Type, 'Ticket', "mysearch is still for tickets");
@@ -162,8 +162,8 @@ like($mysearch->GetParameter('Query'), qr/Queue/, "other mysearch object updated
 
 my $genericsearch = RT::SavedSearch->new($curruser);
 $genericsearch->Save(Name => 'generic search',
-		     Type => 'all',
-		     SearchParams => {'Query' => "Queue = 'General'"});
+                     Type => 'all',
+                     SearchParams => {'Query' => "Queue = 'General'"});
 
 my $ticketsearches = RT::SavedSearches->new($curruser);
 $ticketsearches->LimitToPrivacy('RT::User-'.$curruser->Id, 'Ticket');
diff --git a/t/api/system.t b/t/api/system.t
index c1df2c6..b960392 100644
--- a/t/api/system.t
+++ b/t/api/system.t
@@ -12,8 +12,8 @@ BEGIN{
 # look like RT::Record.
 
 can_ok('RT::System', qw( AvailableRights RightCategories AddRights AddRightCategories
-			 id Id SubjectTag Name QueueCacheNeedsUpdate AddUpgradeHistory
-			 UpgradeHistory ));
+                         id Id SubjectTag Name QueueCacheNeedsUpdate AddUpgradeHistory
+                         UpgradeHistory ));
 
 {
 
diff --git a/t/articles/interface.t b/t/articles/interface.t
index 85782bf..cb2ea72 100644
--- a/t/articles/interface.t
+++ b/t/articles/interface.t
@@ -20,11 +20,11 @@ my ($ret, $msg);
 # Create a test class
 my $class = RT::Class->new($RT::SystemUser);
 ($ret, $msg) = $class->Create('Name' => 'tlaTestClass-'.$$,
-			      'Description' => 'A general-purpose test class');
+                              'Description' => 'A general-purpose test class');
 ok($ret, "Test class created");
 my $class2 = RT::Class->new($RT::SystemUser);
 ($ret, $msg) = $class2->Create('Name' => 'tlaTestClass2-'.$$,
-			      'Description' => 'Another general-purpose test class');
+                              'Description' => 'Another general-purpose test class');
 ok($ret, "Test class 2 created");
 
 
@@ -36,34 +36,34 @@ my $topic2 = RT::Topic->new($RT::SystemUser);
 my $topic_class2= RT::Topic->new($RT::SystemUser);
 my $gtopic = RT::Topic->new($RT::SystemUser);
 ($ret, $msg) = $topic1->Create('Parent' => 0,
-			      'Name' => 'tlaTestTopic1-'.$$,
-			      'ObjectType' => 'RT::Class',
-			      'ObjectId' => $class->Id);
+                               'Name' => 'tlaTestTopic1-'.$$,
+                               'ObjectType' => 'RT::Class',
+                               'ObjectId' => $class->Id);
 ok($ret, "Topic 1 created");
 ($ret, $msg) = $topic11->Create('Parent' => $topic1->Id,
-			       'Name' => 'tlaTestTopic1.1-'.$$,
-			       'ObjectType' => 'RT::Class',
-			       'ObjectId' => $class->Id);
+                                'Name' => 'tlaTestTopic1.1-'.$$,
+                                'ObjectType' => 'RT::Class',
+                                'ObjectId' => $class->Id);
 ok($ret, "Topic 1.1 created");
 ($ret, $msg) = $topic12->Create('Parent' => $topic1->Id,
-			       'Name' => 'tlaTestTopic1.2-'.$$,
-			       'ObjectType' => 'RT::Class',
-			       'ObjectId' => $class->Id);
+                                'Name' => 'tlaTestTopic1.2-'.$$,
+                                'ObjectType' => 'RT::Class',
+                                'ObjectId' => $class->Id);
 ok($ret, "Topic 1.2 created");
 ($ret, $msg) = $topic2->Create('Parent' => 0,
-			      'Name' => 'tlaTestTopic2-'.$$,
-			      'ObjectType' => 'RT::Class',
-			      'ObjectId' => $class->Id);
+                               'Name' => 'tlaTestTopic2-'.$$,
+                               'ObjectType' => 'RT::Class',
+                               'ObjectId' => $class->Id);
 ok($ret, "Topic 2 created");
 ($ret, $msg) = $topic_class2->Create('Parent' => 0,
-			      'Name' => 'tlaTestTopicClass2-'.$$,
-			      'ObjectType' => 'RT::Class',
-			      'ObjectId' => $class2->Id);
+                                     'Name' => 'tlaTestTopicClass2-'.$$,
+                                     'ObjectType' => 'RT::Class',
+                                     'ObjectId' => $class2->Id);
 ok($ret, "Topic Class2 created");
 ($ret, $msg) = $gtopic->Create('Parent' => 0,
-			      'Name' => 'tlaTestTopicGlobal-'.$$,
-			      'ObjectType' => 'RT::System',
-			      'ObjectId' => $RT::System->Id );
+                               'Name' => 'tlaTestTopicGlobal-'.$$,
+                               'ObjectType' => 'RT::System',
+                               'ObjectId' => $RT::System->Id );
 ok($ret, "Global Topic created");
 
 # Create some article custom fields
@@ -71,18 +71,18 @@ ok($ret, "Global Topic created");
 my $questionCF = RT::CustomField->new($RT::SystemUser);
 my $answerCF = RT::CustomField->new($RT::SystemUser);
 ($ret, $msg) = $questionCF->Create('Name' => 'Question-'.$$,
-			   'Type' => 'Text',
-			   'MaxValues' => 1,
-			   'LookupType' => 'RT::Class-RT::Article',
-			   'Description' => 'The question to be answered',
-			   'Disabled' => 0);
+                                   'Type' => 'Text',
+                                   'MaxValues' => 1,
+                                   'LookupType' => 'RT::Class-RT::Article',
+                                   'Description' => 'The question to be answered',
+                                   'Disabled' => 0);
 ok($ret, "Question CF created: $msg");
 ($ret, $msg) = $answerCF->Create('Name' => 'Answer-'.$$,
-			 'Type' => 'Text',
-			 'MaxValues' => 1,
-			 'LookupType' => 'RT::Class-RT::Article',
-			 'Description' => 'The answer to the question',
-			 'Disabled' => 0);
+                                 'Type' => 'Text',
+                                 'MaxValues' => 1,
+                                 'LookupType' => 'RT::Class-RT::Article',
+                                 'Description' => 'The answer to the question',
+                                 'Disabled' => 0);
 ok($ret, "Answer CF created: $msg");
 
 # Attach the custom fields to our class
@@ -93,13 +93,13 @@ ok($ret, "Answer CF added to class: $msg");
 my ($qid, $aid) = ($questionCF->Id, $answerCF->Id);
 
 my %cvals = ('article1q' => 'Some question about swallows',
-		'article1a' => 'Some answer about Europe and Africa',
-		'article2q' => 'Another question about Monty Python',
-		'article2a' => 'Romani ite domum',
-		'article3q' => 'Why should I eat my supper?',
-		'article3a' => 'There are starving children in Africa',
-		'article4q' => 'What did Brian originally write?',
-		'article4a' => 'Romanes eunt domus');
+             'article1a' => 'Some answer about Europe and Africa',
+             'article2q' => 'Another question about Monty Python',
+             'article2a' => 'Romani ite domum',
+             'article3q' => 'Why should I eat my supper?',
+             'article3a' => 'There are starving children in Africa',
+             'article4q' => 'What did Brian originally write?',
+             'article4a' => 'Romanes eunt domus');
 
 # Create an article or two with our custom field values.
 
@@ -108,36 +108,36 @@ my $article2 = RT::Article->new($RT::SystemUser);
 my $article3 = RT::Article->new($RT::SystemUser);
 my $article4 = RT::Article->new($RT::SystemUser);
 ($ret, $msg) = $article1->Create(Name => 'First article '.$$,
-				 Summary => 'blah blah 1',
-				 Class => $class->Id,
-				 Topics => [$topic1->Id],
-				 "CustomField-$qid" => $cvals{'article1q'},
-				 "CustomField-$aid" => $cvals{'article1a'},
-				 );
+                                 Summary => 'blah blah 1',
+                                 Class => $class->Id,
+                                 Topics => [$topic1->Id],
+                                 "CustomField-$qid" => $cvals{'article1q'},
+                                 "CustomField-$aid" => $cvals{'article1a'},
+                                 );
 ok($ret, "article 1 created");
 ($ret, $msg) = $article2->Create(Name => 'Second article '.$$,
-				 Summary => 'foo bar 2',
-				 Class => $class->Id,
-				 Topics => [$topic11->Id],
-				 "CustomField-$qid" => $cvals{'article2q'},
-				 "CustomField-$aid" => $cvals{'article2a'},
-				 );
+                                 Summary => 'foo bar 2',
+                                 Class => $class->Id,
+                                 Topics => [$topic11->Id],
+                                 "CustomField-$qid" => $cvals{'article2q'},
+                                 "CustomField-$aid" => $cvals{'article2a'},
+                                 );
 ok($ret, "article 2 created");
 ($ret, $msg) = $article3->Create(Name => 'Third article '.$$,
-				 Summary => 'ping pong 3',
-				 Class => $class->Id,
-				 Topics => [$topic12->Id],
-				 "CustomField-$qid" => $cvals{'article3q'},
-				 "CustomField-$aid" => $cvals{'article3a'},
-				 );
+                                 Summary => 'ping pong 3',
+                                 Class => $class->Id,
+                                 Topics => [$topic12->Id],
+                                 "CustomField-$qid" => $cvals{'article3q'},
+                                 "CustomField-$aid" => $cvals{'article3a'},
+                                 );
 ok($ret, "article 3 created");
 ($ret, $msg) = $article4->Create(Name => 'Fourth article '.$$,
-				 Summary => 'hoi polloi 4',
-				 Class => $class->Id,
-				 Topics => [$topic2->Id],
-				 "CustomField-$qid" => $cvals{'article4q'},
-				 "CustomField-$aid" => $cvals{'article4a'},
-				 );
+                                 Summary => 'hoi polloi 4',
+                                 Class => $class->Id,
+                                 Topics => [$topic2->Id],
+                                 "CustomField-$qid" => $cvals{'article4q'},
+                                 "CustomField-$aid" => $cvals{'article4a'},
+                                 );
 ok($ret, "article 4 created");
 
 # Create a ticket.
@@ -152,8 +152,8 @@ May as well say something about Africa.');
 my $ticket = RT::Ticket->new($RT::SystemUser);
 my $obj;
 ($ret, $obj, $msg) = $ticket->Create(Queue => 'General',
-			       Subject => 'test ticket for articles '.$$,
-			       MIMEObj => $parser->Entity);
+                                     Subject => 'test ticket for articles '.$$,
+                                     MIMEObj => $parser->Entity);
 ok($ret, "Test ticket for articles created: $msg");
 
 
@@ -175,9 +175,9 @@ my $ticket_id = $ticket->Id;
 my $turi = "t:$ticket_id";
 my $a1uri = 'a:'.$article1->Id;
 $m->submit_form(form_name => 'EditArticle',
-		fields => { $article3->Id.'-RefersTo' => $turi,
-			    'RefersTo-'.$article3->Id => $a1uri }
-		);
+                fields => { $article3->Id.'-RefersTo' => $turi,
+                            'RefersTo-'.$article3->Id => $a1uri }
+                );
 
 $m->content_like(qr/Ticket.*$ticket_id/, "Ticket linkto was created");
 $m->content_like(qr/URI.*$a1uri/, "Article linkfrom was created");
@@ -185,7 +185,7 @@ $m->content_like(qr/URI.*$a1uri/, "Article linkfrom was created");
 
 # Now try to extract an article from a link.
 $m->get_ok($url."/Ticket/Display.html?id=".$ticket->Id, 
-	   "Loaded ticket display");
+           "Loaded ticket display");
 $m->content_like(qr/Extract Article/, "Article extraction link shows up");
 $m->follow_link_ok( { text => 'Extract Article' }, '-> Extract Article' );
 $m->content_contains($class->Name);
@@ -203,7 +203,7 @@ $m->title_like(qr/Modify article/);
 $m->follow_link_ok( { text => 'Display' }, '-> Display' );
 $m->content_like(qr/Africa/, "Article content exist");
 $m->content_contains($ticket->Subject,
-		     "Article references originating ticket");
+                     "Article references originating ticket");
 
 diag("Test creating a ticket in Class2 and make sure we don't see Class1 Topics") if $ENV{TEST_VERBOSE};
 {
diff --git a/t/articles/search-interface.t b/t/articles/search-interface.t
index 1e17c29..ce32145 100644
--- a/t/articles/search-interface.t
+++ b/t/articles/search-interface.t
@@ -19,7 +19,7 @@ my ($ret, $msg);
 # Create a test class
 my $class = RT::Class->new($RT::SystemUser);
 ($ret, $msg) = $class->Create('Name' => 'tlaTestClass-'.$$,
-			      'Description' => 'A general-purpose test class');
+                              'Description' => 'A general-purpose test class');
 ok($ret, "Test class created");
 
 
@@ -27,25 +27,25 @@ my $questionCF = RT::CustomField->new($RT::SystemUser);
 my $answerCF = RT::CustomField->new($RT::SystemUser);
 my $ticketCF = RT::CustomField->new($RT::SystemUser);
 ($ret, $msg) = $questionCF->Create('Name' => 'Question-'.$$,
-			   'Type' => 'Text',
-			   'MaxValues' => 1,
-			   'LookupType' => 'RT::Class-RT::Article',
-			   'Description' => 'The question to be answered',
-			   'Disabled' => 0);
+                           'Type' => 'Text',
+                           'MaxValues' => 1,
+                           'LookupType' => 'RT::Class-RT::Article',
+                           'Description' => 'The question to be answered',
+                           'Disabled' => 0);
 ok($ret, "Question CF created: $msg");
 ($ret, $msg) = $answerCF->Create('Name' => 'Answer-'.$$,
-			 'Type' => 'Text',
-			 'MaxValues' => 1,
-			 'LookupType' => 'RT::Class-RT::Article',
-			 'Description' => 'The answer to the question',
-			 'Disabled' => 0);
+                         'Type' => 'Text',
+                         'MaxValues' => 1,
+                         'LookupType' => 'RT::Class-RT::Article',
+                         'Description' => 'The answer to the question',
+                         'Disabled' => 0);
 ok($ret, "Answer CF created: $msg");
 
 ($ret, $msg) = $ticketCF->Create('Name' => 'Class',
-			 'Type' => 'Text',
-			 'MaxValues' => 1,
-			 'LookupType' => 'RT::Queue-RT::Ticket',
-			 'Disabled' => 0);
+                         'Type' => 'Text',
+                         'MaxValues' => 1,
+                         'LookupType' => 'RT::Queue-RT::Ticket',
+                         'Disabled' => 0);
 ok($ret, "Ticket CF 'Class' created: $msg");
 
 # Attach the custom fields to our class
@@ -60,18 +60,18 @@ my $global_queue = RT::Queue->new($RT::SystemUser);
 ok($ret, "Ticket CF added globally: $msg");
 
 my %cvals = ('article1q' => 'Some question about swallows',
-		'article1a' => 'Some answer about Europe and Africa',
-		'article2q' => 'Another question about Monty Python',
-		'article2a' => 'Romani ite domum',
-		'article3q' => 'Why should I eat my supper?',
-		'article3a' => 'There are starving children in Africa',
-		'article4q' => 'What did Brian originally write?',
-		'article4a' => 'This is an answer that is longer than 255 '
-	     . 'characters so these tests will be sure to use the LargeContent '
-	     . 'SQL as well as the normal SQL that would be generated if this '
-	     . 'was an answer that was shorter than 255 characters. This second '
-	     . 'sentence has a few extra characters to get this string to go '
-	     . 'over the 255 character boundary. Lorem ipsum.');
+                'article1a' => 'Some answer about Europe and Africa',
+                'article2q' => 'Another question about Monty Python',
+                'article2a' => 'Romani ite domum',
+                'article3q' => 'Why should I eat my supper?',
+                'article3a' => 'There are starving children in Africa',
+                'article4q' => 'What did Brian originally write?',
+                'article4a' => 'This is an answer that is longer than 255 '
+             . 'characters so these tests will be sure to use the LargeContent '
+             . 'SQL as well as the normal SQL that would be generated if this '
+             . 'was an answer that was shorter than 255 characters. This second '
+             . 'sentence has a few extra characters to get this string to go '
+             . 'over the 255 character boundary. Lorem ipsum.');
 
 # Create an article or two with our custom field values.
 
@@ -80,32 +80,32 @@ my $article2 = RT::Article->new($RT::SystemUser);
 my $article3 = RT::Article->new($RT::SystemUser);
 my $article4 = RT::Article->new($RT::SystemUser);
 ($ret, $msg) = $article1->Create(Name => 'First article '.$$,
-				 Summary => 'blah blah 1',
-				 Class => $class->Id,
-				 "CustomField-$qid" => $cvals{'article1q'},
-				 "CustomField-$aid" => $cvals{'article1a'},
-				 );
+                                 Summary => 'blah blah 1',
+                                 Class => $class->Id,
+                                 "CustomField-$qid" => $cvals{'article1q'},
+                                 "CustomField-$aid" => $cvals{'article1a'},
+                                 );
 ok($ret, "article 1 created");
 ($ret, $msg) = $article2->Create(Name => 'Second article '.$$,
-				 Summary => 'foo bar 2',
-				 Class => $class->Id,
-				 "CustomField-$qid" => $cvals{'article2q'},
-				 "CustomField-$aid" => $cvals{'article2a'},
-				 );
+                                 Summary => 'foo bar 2',
+                                 Class => $class->Id,
+                                 "CustomField-$qid" => $cvals{'article2q'},
+                                 "CustomField-$aid" => $cvals{'article2a'},
+                                 );
 ok($ret, "article 2 created");
 ($ret, $msg) = $article3->Create(Name => 'Third article '.$$,
-				 Summary => 'ping pong 3',
-				 Class => $class->Id,
-				 "CustomField-$qid" => $cvals{'article3q'},
-				 "CustomField-$aid" => $cvals{'article3a'},
-				 );
+                                 Summary => 'ping pong 3',
+                                 Class => $class->Id,
+                                 "CustomField-$qid" => $cvals{'article3q'},
+                                 "CustomField-$aid" => $cvals{'article3a'},
+                                 );
 ok($ret, "article 3 created");
 ($ret, $msg) = $article4->Create(Name => 'Fourth article '.$$,
-				 Summary => 'hoi polloi 4',
-				 Class => $class->Id,
-				 "CustomField-$qid" => $cvals{'article4q'},
-				 "CustomField-$aid" => $cvals{'article4a'},
-				 );
+                                 Summary => 'hoi polloi 4',
+                                 Class => $class->Id,
+                                 "CustomField-$qid" => $cvals{'article4q'},
+                                 "CustomField-$aid" => $cvals{'article4a'},
+                                 );
 ok($ret, "article 4 created");
 
 isa_ok($m, 'Test::WWW::Mechanize');
diff --git a/t/articles/set-subject.t b/t/articles/set-subject.t
index 5b054e8..9b9ff85 100644
--- a/t/articles/set-subject.t
+++ b/t/articles/set-subject.t
@@ -17,7 +17,7 @@ my ($ret, $msg);
 # Create a test class
 my $class = RT::Class->new($RT::SystemUser);
 ($ret, $msg) = $class->Create('Name' => 'TestClass-'.$$,
-			      'Description' => 'A general-purpose test class');
+                              'Description' => 'A general-purpose test class');
 ok($ret, "Test class created: $msg");
 # because id 0 represents global, it uses an empty Queue object...
 ($ret, $msg) = $class->AddToObject(RT::Queue->new($RT::SystemUser));
@@ -27,18 +27,18 @@ ok($ret, "Applied Class globally: $msg");
 my $bodyCF    = RT::CustomField->new($RT::SystemUser);
 my $subjectCF = RT::CustomField->new($RT::SystemUser);
 ($ret, $msg) = $subjectCF->Create('Name' => 'Subject-'.$$,
-			   'Type' => 'Text',
-			   'MaxValues' => 1,
-			   'LookupType' => 'RT::Class-RT::Article',
-			   'Description' => 'The subject to be answered',
-			   'Disabled' => 0);
+                           'Type' => 'Text',
+                           'MaxValues' => 1,
+                           'LookupType' => 'RT::Class-RT::Article',
+                           'Description' => 'The subject to be answered',
+                           'Disabled' => 0);
 ok($ret, "Question CF created: $msg");
 ($ret, $msg) = $bodyCF->Create('Name' => 'Body-'.$$,
-			 'Type' => 'Text',
-			 'MaxValues' => 1,
-			 'LookupType' => 'RT::Class-RT::Article',
-			 'Description' => 'The body to the subject',
-			 'Disabled' => 0);
+                         'Type' => 'Text',
+                         'MaxValues' => 1,
+                         'LookupType' => 'RT::Class-RT::Article',
+                         'Description' => 'The body to the subject',
+                         'Disabled' => 0);
 ok($ret, "Answer CF created: $msg");
 my ($sid, $bid) = ($subjectCF->Id, $bodyCF->Id);
 
@@ -50,11 +50,11 @@ ok($ret, "Body CF added to class: $msg");
 
 my $article = RT::Article->new($RT::SystemUser);
 ($ret, $msg) = $article->Create(Name => 'First article '.$$,
-				 Summary => 'blah blah 1',
-				 Class => $class->Id,
-				 "CustomField-$bid" => 'This goes in the body', 
-				 "CustomField-$sid" => 'This clobbers your subject',
-				 );
+                                Summary => 'blah blah 1',
+                                Class => $class->Id,
+                                "CustomField-$bid" => 'This goes in the body', 
+                                "CustomField-$sid" => 'This clobbers your subject',
+                            );
 ok($ret, "article 1 created: $msg");
 
 # Create a ticket.
@@ -69,8 +69,8 @@ May as well say something about Africa.');
 my $ticket = RT::Ticket->new($RT::SystemUser);
 my $obj;
 ($ret, $obj, $msg) = $ticket->Create(Queue => 'General',
-			       Subject => 'test ticket for articles '.$$,
-			       MIMEObj => $parser->Entity);
+                                     Subject => 'test ticket for articles '.$$,
+                                     MIMEObj => $parser->Entity);
 ok($ret, "Test ticket for articles created: $msg");
 
 
diff --git a/t/articles/upload-customfields.t b/t/articles/upload-customfields.t
index c75fbcf..0656168 100644
--- a/t/articles/upload-customfields.t
+++ b/t/articles/upload-customfields.t
@@ -25,7 +25,7 @@ use constant ImageFileContent => do {
 use RT::Class;
 my $class = RT::Class->new($RT::SystemUser);
 my ($ret, $msg) = $class->Create('Name' => 'tlaTestClass-'.$$,
-			      'Description' => 'A general-purpose test class');
+                                 'Description' => 'A general-purpose test class');
 ok($ret, "Test class created");
 
 
diff --git a/t/customfields/api.t b/t/customfields/api.t
index 2e1c079..a50ca77 100644
--- a/t/customfields/api.t
+++ b/t/customfields/api.t
@@ -5,12 +5,12 @@ use warnings FATAL => 'all';
 use RT::Test nodata => 1, tests => 145;
 use Test::Warn;
 
-# Before we get going, ditch all object_cfs; this will remove 
+# Before we get going, ditch all object_cfs; this will remove
 # all custom fields systemwide;
 my $object_cfs = RT::ObjectCustomFields->new(RT->SystemUser);
 $object_cfs->UnLimit();
 while (my $ocf = $object_cfs->Next) {
-	$ocf->Delete();
+    $ocf->Delete();
 }
 
 
@@ -23,9 +23,9 @@ $queue2->Create( Name => 'RecordCustomFields2' );
 
 my $ticket = RT::Ticket->new( RT->SystemUser );
 $ticket->Create(
-	Queue => $queue->Id,
-	Requestor => 'root at localhost',
-	Subject => 'RecordCustomFields1',
+    Queue => $queue->Id,
+    Requestor => 'root at localhost',
+    Subject => 'RecordCustomFields1',
 );
 
 my $cfs = $ticket->CustomFields;
@@ -86,13 +86,13 @@ warning_like {
 } qr{Couldn't load custom field};
 
 for (@custom_fields) {
-	$cfvs = $ticket->CustomFieldValues( $_->id );
-	is( $cfvs->Count, 0 );
+    $cfvs = $ticket->CustomFieldValues( $_->id );
+    is( $cfvs->Count, 0 );
 
-	$cfvs = $ticket->CustomFieldValues( $_->Name );
-	is( $cfvs->Count, 0 );
-	is( $ticket->FirstCustomFieldValue( $_->id ), undef );
-	is( $ticket->FirstCustomFieldValue( $_->Name ), undef );
+    $cfvs = $ticket->CustomFieldValues( $_->Name );
+    is( $cfvs->Count, 0 );
+    is( $ticket->FirstCustomFieldValue( $_->id ), undef );
+    is( $ticket->FirstCustomFieldValue( $_->Name ), undef );
 }
 
 # try to add field value with fields that do not exist {{{
@@ -103,84 +103,84 @@ ok(!$status, "shouldn't add value" );
 
 SKIP: {
 
-	skip "TODO: We want fields that are not allowed to set unexpected values", 10;
-	for (@custom_fields) {
-		($status, $msg) = $ticket->AddCustomFieldValue( Field => $_ , Value => 'SomeUnexpectedCFValue' );
-		ok( !$status, 'value doesn\'t exist');
-	
-		($status, $msg) = $ticket->AddCustomFieldValue( Field => $_->id , Value => 'SomeUnexpectedCFValue' );
-		ok( !$status, 'value doesn\'t exist');
-	
-		($status, $msg) = $ticket->AddCustomFieldValue( Field => $_->Name , Value => 'SomeUnexpectedCFValue' );
-		ok( !$status, 'value doesn\'t exist');
-	}
-	
-	# Let check that we did not add value to be sure
-	# using only FirstCustomFieldValue sub because
-	# we checked other variants allready
-	for (@custom_fields) {
-		is( $ticket->FirstCustomFieldValue( $_->id ), undef );
-	}
-	
+    skip "TODO: We want fields that are not allowed to set unexpected values", 10;
+    for (@custom_fields) {
+        ($status, $msg) = $ticket->AddCustomFieldValue( Field => $_ , Value => 'SomeUnexpectedCFValue' );
+        ok( !$status, 'value doesn\'t exist');
+
+        ($status, $msg) = $ticket->AddCustomFieldValue( Field => $_->id , Value => 'SomeUnexpectedCFValue' );
+        ok( !$status, 'value doesn\'t exist');
+
+        ($status, $msg) = $ticket->AddCustomFieldValue( Field => $_->Name , Value => 'SomeUnexpectedCFValue' );
+        ok( !$status, 'value doesn\'t exist');
+    }
+
+    # Let check that we did not add value to be sure
+    # using only FirstCustomFieldValue sub because
+    # we checked other variants allready
+    for (@custom_fields) {
+        is( $ticket->FirstCustomFieldValue( $_->id ), undef );
+    }
+
 }
 # Add some values to our custom fields
 for (@custom_fields) {
-	# this should be tested elsewhere
-	$_->AddValue( Name => 'Foo' );
-	$_->AddValue( Name => 'Bar' );
+    # this should be tested elsewhere
+    $_->AddValue( Name => 'Foo' );
+    $_->AddValue( Name => 'Bar' );
 }
 
 my $test_add_delete_cycle = sub {
-	my $cb = shift;
-	for (@custom_fields) {
-		($status, $msg) = $ticket->AddCustomFieldValue( Field => $cb->($_) , Value => 'Foo' );
-		ok( $status, "message: $msg");
-	}
-	
-	# does it exist?
-	$cfvs = $ticket->CustomFieldValues;
-	is( $cfvs->Count, 3, "We found all three custom fields on our ticket" );
-	for (@custom_fields) {
-		$cfvs = $ticket->CustomFieldValues( $_->id );
-		is( $cfvs->Count, 1 , "we found one custom field when searching by id");
-	
-		$cfvs = $ticket->CustomFieldValues( $_->Name );
-		is( $cfvs->Count, 1 , " We found one custom field when searching by name for " . $_->Name);
-		is( $ticket->FirstCustomFieldValue( $_->id ), 'Foo' , "first value by id is foo");
-		is( $ticket->FirstCustomFieldValue( $_->Name ), 'Foo' , "first value by name is foo");
-	}
-	# because our CFs are SingleValue then new value addition should override
-	for (@custom_fields) {
-		($status, $msg) = $ticket->AddCustomFieldValue( Field => $_ , Value => 'Bar' );
-		ok( $status, "message: $msg");
-	}
-	$cfvs = $ticket->CustomFieldValues;
-	is( $cfvs->Count, 3 );
-	for (@custom_fields) {
-		$cfvs = $ticket->CustomFieldValues( $_->id );
-		is( $cfvs->Count, 1 );
-	
-		$cfvs = $ticket->CustomFieldValues( $_->Name );
-		is( $cfvs->Count, 1 );
-		is( $ticket->FirstCustomFieldValue( $_->id ), 'Bar' );
-		is( $ticket->FirstCustomFieldValue( $_->Name ), 'Bar' );
-	}
-	# delete it
-	for (@custom_fields ) { 
-		($status, $msg) = $ticket->DeleteCustomFieldValue( Field => $_ , Value => 'Bar' );
-		ok( $status, "Deleted a custom field value 'Bar' for field ".$_->id.": $msg");
-	}
-	$cfvs = $ticket->CustomFieldValues;
-	is( $cfvs->Count, 0, "The ticket (".$ticket->id.") no longer has any custom field values"  );
-	for (@custom_fields) {
-		$cfvs = $ticket->CustomFieldValues( $_->id );
-		is( $cfvs->Count, 0,  $ticket->id." has no values for cf  ".$_->id );
-	
-		$cfvs = $ticket->CustomFieldValues( $_->Name );
-		is( $cfvs->Count, 0 , $ticket->id." has no values for cf  '".$_->Name. "'" );
-		is( $ticket->FirstCustomFieldValue( $_->id ), undef , "There is no first custom field value when loading by id" );
-		is( $ticket->FirstCustomFieldValue( $_->Name ), undef, "There is no first custom field value when loading by Name" );
-	}
+    my $cb = shift;
+    for (@custom_fields) {
+        ($status, $msg) = $ticket->AddCustomFieldValue( Field => $cb->($_) , Value => 'Foo' );
+        ok( $status, "message: $msg");
+    }
+
+    # does it exist?
+    $cfvs = $ticket->CustomFieldValues;
+    is( $cfvs->Count, 3, "We found all three custom fields on our ticket" );
+    for (@custom_fields) {
+        $cfvs = $ticket->CustomFieldValues( $_->id );
+        is( $cfvs->Count, 1 , "we found one custom field when searching by id");
+
+        $cfvs = $ticket->CustomFieldValues( $_->Name );
+        is( $cfvs->Count, 1 , " We found one custom field when searching by name for " . $_->Name);
+        is( $ticket->FirstCustomFieldValue( $_->id ), 'Foo' , "first value by id is foo");
+        is( $ticket->FirstCustomFieldValue( $_->Name ), 'Foo' , "first value by name is foo");
+    }
+    # because our CFs are SingleValue then new value addition should override
+    for (@custom_fields) {
+        ($status, $msg) = $ticket->AddCustomFieldValue( Field => $_ , Value => 'Bar' );
+        ok( $status, "message: $msg");
+    }
+    $cfvs = $ticket->CustomFieldValues;
+    is( $cfvs->Count, 3 );
+    for (@custom_fields) {
+        $cfvs = $ticket->CustomFieldValues( $_->id );
+        is( $cfvs->Count, 1 );
+
+        $cfvs = $ticket->CustomFieldValues( $_->Name );
+        is( $cfvs->Count, 1 );
+        is( $ticket->FirstCustomFieldValue( $_->id ), 'Bar' );
+        is( $ticket->FirstCustomFieldValue( $_->Name ), 'Bar' );
+    }
+    # delete it
+    for (@custom_fields ) {
+        ($status, $msg) = $ticket->DeleteCustomFieldValue( Field => $_ , Value => 'Bar' );
+        ok( $status, "Deleted a custom field value 'Bar' for field ".$_->id.": $msg");
+    }
+    $cfvs = $ticket->CustomFieldValues;
+    is( $cfvs->Count, 0, "The ticket (".$ticket->id.") no longer has any custom field values"  );
+    for (@custom_fields) {
+        $cfvs = $ticket->CustomFieldValues( $_->id );
+        is( $cfvs->Count, 0,  $ticket->id." has no values for cf  ".$_->id );
+
+        $cfvs = $ticket->CustomFieldValues( $_->Name );
+        is( $cfvs->Count, 0 , $ticket->id." has no values for cf  '".$_->Name. "'" );
+        is( $ticket->FirstCustomFieldValue( $_->id ), undef , "There is no first custom field value when loading by id" );
+        is( $ticket->FirstCustomFieldValue( $_->Name ), undef, "There is no first custom field value when loading by Name" );
+    }
 };
 
 # lets test cycle via CF id
@@ -224,10 +224,10 @@ warning_like {
 }
 
 #SKIP: {
-#	skip "TODO: should we add CF values to objects via CF Name?", 48;
+#       skip "TODO: should we add CF values to objects via CF Name?", 48;
 # names are not unique
-	# lets test cycle via CF Name
-#	$test_add_delete_cycle->( sub { return $_[0]->Name } );
+        # lets test cycle via CF Name
+#       $test_add_delete_cycle->( sub { return $_[0]->Name } );
 #}
 
 
diff --git a/t/mail/digest-attributes.t b/t/mail/digest-attributes.t
index badd59b..22e457c 100644
--- a/t/mail/digest-attributes.t
+++ b/t/mail/digest-attributes.t
@@ -51,48 +51,48 @@ my $everyone = RT::Group->new( RT->SystemUser );
 ok( $ret, "Loaded 'everyone' group: $msg" );
 
 ( $ret, $msg ) = $everyone->PrincipalObj->GrantRight( Right => 'CreateTicket',
-						      Object => $testq );
+                                                      Object => $testq );
 ok( $ret || $msg =~ /already has/, "Granted everyone CreateTicket on testq: $msg" );
 
 # Make user_d an admincc for the queue.
 ( $ret, $msg ) = $user_d->PrincipalObj->GrantRight( Right => 'AdminQueue',
-						    Object => $testq );
+                                                    Object => $testq );
 ok( $ret || $msg =~ /already has/, "Granted dduser AdminQueue on testq: $msg" );
 ( $ret, $msg ) = $testq->AddWatcher( Type => 'AdminCc',
-			     PrincipalId => $user_d->PrincipalObj->id );
+                             PrincipalId => $user_d->PrincipalObj->id );
 ok( $ret || $msg =~ /already/, "dduser added as a queue watcher: $msg" );
 
 # Give the others queue rights.
 ( $ret, $msg ) = $user_n->PrincipalObj->GrantRight( Right => 'AdminQueue',
-						    Object => $testq );
+                                                    Object => $testq );
 ok( $ret || $msg =~ /already has/, "Granted emailnormal right on testq: $msg" );
 ( $ret, $msg ) = $user_w->PrincipalObj->GrantRight( Right => 'AdminQueue',
-						    Object => $testq );
+                                                    Object => $testq );
 ok( $ret || $msg =~ /already has/, "Granted emailweekly right on testq: $msg" );
 ( $ret, $msg ) = $user_s->PrincipalObj->GrantRight( Right => 'AdminQueue',
-						    Object => $testq );
+                                                    Object => $testq );
 ok( $ret || $msg =~ /already has/, "Granted emailsusp right on testq: $msg" );
 
 # Create a ticket with To: Cc: Bcc: fields using our four users.
 my $id;
 my $ticket = RT::Ticket->new( RT->SystemUser );
 ( $id, $ret, $msg ) = $ticket->Create( Queue => $testq->Name,
-				       Requestor => [ $user_w->Name ],
-				       Subject => 'Test ticket for RT::Extension::EmailDigest',
-				       );
+                                       Requestor => [ $user_w->Name ],
+                                       Subject => 'Test ticket for RT::Extension::EmailDigest',
+                                       );
 ok( $ret, "Ticket $id created: $msg" );
 
 # Make the other users ticket watchers.
 ( $ret, $msg ) = $ticket->AddWatcher( Type => 'Cc',
-		      PrincipalId => $user_n->PrincipalObj->id );
+                      PrincipalId => $user_n->PrincipalObj->id );
 ok( $ret, "Added user_n as a ticket watcher: $msg" );
 ( $ret, $msg ) = $ticket->AddWatcher( Type => 'Cc',
-		      PrincipalId => $user_s->PrincipalObj->id );
+                      PrincipalId => $user_s->PrincipalObj->id );
 ok( $ret, "Added user_s as a ticket watcher: $msg" );
 
 my $obj;
 ($id, $msg, $obj ) = $ticket->Correspond(
-	Content => "This is a ticket response for CC action" );
+    Content => "This is a ticket response for CC action" );
 ok( $ret, "Transaction created: $msg" );
 
 # Get the deferred notifications that should result.  Should be two for
@@ -113,11 +113,11 @@ while( my $txn = $txns->Next ) {
 
     # If the transaction has content...
     if( $txn->ContentObj ) {
-	# ...none of the deferred folk should be in the header.
-	my $headerstr = $txn->ContentObj->Headers;
-	foreach my $rcpt( @daily_rcpt, @weekly_rcpt, @susp_rcpt ) {
-	    ok( $headerstr !~ /$rcpt/, "Deferred recipient $rcpt not found in header" );
-	}
+        # ...none of the deferred folk should be in the header.
+        my $headerstr = $txn->ContentObj->Headers;
+        foreach my $rcpt( @daily_rcpt, @weekly_rcpt, @susp_rcpt ) {
+            ok( $headerstr !~ /$rcpt/, "Deferred recipient $rcpt not found in header" );
+        }
     }
 }
 
diff --git a/t/mail/gateway.t b/t/mail/gateway.t
index faabfeb..9f1d288 100644
--- a/t/mail/gateway.t
+++ b/t/mail/gateway.t
@@ -705,10 +705,10 @@ is( $tick->Transactions->Count, 7, 'no superfluous transactions');
 use RT::User;
 my $user = RT::User->new( RT->SystemUser );
 my ($uid) = $user->Create( Name => 'ext-mailgate',
-			   EmailAddress => 'ext-mailgate at localhost',
-			   Privileged => 1,
-			   Password => 'qwe123',
-			 );
+                           EmailAddress => 'ext-mailgate at localhost',
+                           Privileged => 1,
+                           Password => 'qwe123',
+                         );
 ok( $uid, 'user created for ext-mailgate tests' );
 ok( !$user->HasRight( Right => 'OwnTicket', Object => $queue ), "User can't own ticket" );
 
@@ -789,7 +789,7 @@ my $acl = RT::ACL->new(RT->SystemUser);
 $acl->Limit( FIELD => 'RightName', VALUE => 'ReplyToTicket' );
 $acl->LimitToObject( $RT::System );
 while( my $ace = $acl->Next ) {
-	$ace->Delete;
+    $ace->Delete;
 }
 
 ok( !$user->HasRight( Right => 'ReplyToTicket', Object => $tick ), "User can't reply to ticket any more" );
diff --git a/t/mail/gnupg-incoming.t b/t/mail/gnupg-incoming.t
index 48d2d9b..3498d47 100644
--- a/t/mail/gnupg-incoming.t
+++ b/t/mail/gnupg-incoming.t
@@ -28,7 +28,7 @@ ok( $m->login, 'we did log in' );
 $m->get( $baseurl.'/Admin/Queues/');
 $m->follow_link_ok( {text => 'General'} );
 $m->submit_form( form_number => 3,
-		 fields      => { CorrespondAddress => 'general at example.com' } );
+                 fields      => { CorrespondAddress => 'general at example.com' } );
 $m->content_like(qr/general\@example.com.* - never/, 'has key info.');
 
 ok(my $user = RT::User->new(RT->SystemUser));
diff --git a/t/mail/outlook.t b/t/mail/outlook.t
index 752a91f..9c7e715 100644
--- a/t/mail/outlook.t
+++ b/t/mail/outlook.t
@@ -210,8 +210,8 @@ John Smith
 Some Company
 email\@someco.com
 EOF
-	test_email( $text, $content,
-		    ' with base64, no X-Mailer, \n\n are replaced' );
+        test_email( $text, $content,
+                    ' with base64, no X-Mailer, \n\n are replaced' );
 }
 
 
@@ -382,8 +382,8 @@ This isthesig
 
 EOF
 
-	test_email( $text, $content,
-		    'Another sample multipart message with Exchange headers' );
+        test_email( $text, $content,
+                    'Another sample multipart message with Exchange headers' );
 }
 
 sub test_email {
diff --git a/t/shredder/02group_member.t b/t/shredder/02group_member.t
index 4eabf57..87d1e3c 100644
--- a/t/shredder/02group_member.t
+++ b/t/shredder/02group_member.t
@@ -8,128 +8,128 @@ my $test = "RT::Test::Shredder";
 
 ### nested membership check
 {
-	$test->create_savepoint('clean');
-	my $pgroup = RT::Group->new( RT->SystemUser );
-	my ($pgid) = $pgroup->CreateUserDefinedGroup( Name => 'Parent group' );
-	ok( $pgid, "created parent group" );
-	is( $pgroup->id, $pgid, "id is correct" );
-	
-	my $cgroup = RT::Group->new( RT->SystemUser );
-	my ($cgid) = $cgroup->CreateUserDefinedGroup( Name => 'Child group' );
-	ok( $cgid, "created child group" );
-	is( $cgroup->id, $cgid, "id is correct" );
-	
-	my ($status, $msg) = $pgroup->AddMember( $cgroup->id );
-	ok( $status, "added child group to parent") or diag "error: $msg";
-	
-	$test->create_savepoint('bucreate'); # before user create
-	my $user = RT::User->new( RT->SystemUser );
-	my $uid;
-	($uid, $msg) = $user->Create( Name => 'new user', Privileged => 1, Disabled => 0 );
-	ok( $uid, "created new user" ) or diag "error: $msg";
-	is( $user->id, $uid, "id is correct" );
-	
-	$test->create_savepoint('buadd'); # before group add
-	($status, $msg) = $cgroup->AddMember( $user->id );
-	ok( $status, "added user to child group") or diag "error: $msg";
-	
-	my $members = RT::GroupMembers->new( RT->SystemUser );
-	$members->Limit( FIELD => 'MemberId', VALUE => $uid );
-	$members->Limit( FIELD => 'GroupId', VALUE => $cgid );
-	is( $members->Count, 1, "find membership record" );
-	
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $members );
-	$shredder->WipeoutAll();
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('buadd'), "current DB equal to savepoint");
-	
-	$shredder->PutObjects( Objects => $user );
-	$shredder->WipeoutAll();
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('bucreate'), "current DB equal to savepoint");
-	
-	$shredder->PutObjects( Objects => [$pgroup, $cgroup] );
-	$shredder->WipeoutAll();
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+        $test->create_savepoint('clean');
+        my $pgroup = RT::Group->new( RT->SystemUser );
+        my ($pgid) = $pgroup->CreateUserDefinedGroup( Name => 'Parent group' );
+        ok( $pgid, "created parent group" );
+        is( $pgroup->id, $pgid, "id is correct" );
+
+        my $cgroup = RT::Group->new( RT->SystemUser );
+        my ($cgid) = $cgroup->CreateUserDefinedGroup( Name => 'Child group' );
+        ok( $cgid, "created child group" );
+        is( $cgroup->id, $cgid, "id is correct" );
+
+        my ($status, $msg) = $pgroup->AddMember( $cgroup->id );
+        ok( $status, "added child group to parent") or diag "error: $msg";
+
+        $test->create_savepoint('bucreate'); # before user create
+        my $user = RT::User->new( RT->SystemUser );
+        my $uid;
+        ($uid, $msg) = $user->Create( Name => 'new user', Privileged => 1, Disabled => 0 );
+        ok( $uid, "created new user" ) or diag "error: $msg";
+        is( $user->id, $uid, "id is correct" );
+
+        $test->create_savepoint('buadd'); # before group add
+        ($status, $msg) = $cgroup->AddMember( $user->id );
+        ok( $status, "added user to child group") or diag "error: $msg";
+
+        my $members = RT::GroupMembers->new( RT->SystemUser );
+        $members->Limit( FIELD => 'MemberId', VALUE => $uid );
+        $members->Limit( FIELD => 'GroupId', VALUE => $cgid );
+        is( $members->Count, 1, "find membership record" );
+
+        my $shredder = $test->shredder_new();
+        $shredder->PutObjects( Objects => $members );
+        $shredder->WipeoutAll();
+        $test->db_is_valid;
+        cmp_deeply( $test->dump_current_and_savepoint('buadd'), "current DB equal to savepoint");
+
+        $shredder->PutObjects( Objects => $user );
+        $shredder->WipeoutAll();
+        $test->db_is_valid;
+        cmp_deeply( $test->dump_current_and_savepoint('bucreate'), "current DB equal to savepoint");
+
+        $shredder->PutObjects( Objects => [$pgroup, $cgroup] );
+        $shredder->WipeoutAll();
+        $test->db_is_valid;
+        cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 ### deleting member of the ticket AdminCc role group
 {
-	$test->restore_savepoint('clean');
-
-	my $user = RT::User->new( RT->SystemUser );
-	my ($uid, $msg) = $user->Create( Name => 'new user', Privileged => 1, Disabled => 0 );
-	ok( $uid, "created new user" ) or diag "error: $msg";
-	is( $user->id, $uid, "id is correct" );
-
-	use RT::Queue;
-	my $queue = RT::Queue->new( RT->SystemUser );
-	$queue->Load('general');
-	ok( $queue->id, "queue loaded succesfully" );
-
-	use RT::Tickets;
-	my $ticket = RT::Ticket->new( RT->SystemUser );
-	my ($id) = $ticket->Create( Subject => 'test', Queue => $queue->id );
-	ok( $id, "created new ticket" );
-	$ticket = RT::Ticket->new( RT->SystemUser );
-	my $status;
-	($status, $msg) = $ticket->Load( $id );
-	ok( $id, "load ticket" ) or diag( "error: $msg" );
-
-	($status, $msg) = $ticket->AddWatcher( Type => "AdminCc", PrincipalId => $user->id );
-	ok( $status, "AdminCC successfuly added") or diag( "error: $msg" );
-
-	my $member = $ticket->AdminCc->MembersObj->First;
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $member );
-	$shredder->WipeoutAll();
-	$test->db_is_valid;
-
-	$shredder->PutObjects( Objects => $user );
-	$shredder->WipeoutAll();
+        $test->restore_savepoint('clean');
+
+        my $user = RT::User->new( RT->SystemUser );
+        my ($uid, $msg) = $user->Create( Name => 'new user', Privileged => 1, Disabled => 0 );
+        ok( $uid, "created new user" ) or diag "error: $msg";
+        is( $user->id, $uid, "id is correct" );
+
+        use RT::Queue;
+        my $queue = RT::Queue->new( RT->SystemUser );
+        $queue->Load('general');
+        ok( $queue->id, "queue loaded succesfully" );
+
+        use RT::Tickets;
+        my $ticket = RT::Ticket->new( RT->SystemUser );
+        my ($id) = $ticket->Create( Subject => 'test', Queue => $queue->id );
+        ok( $id, "created new ticket" );
+        $ticket = RT::Ticket->new( RT->SystemUser );
+        my $status;
+        ($status, $msg) = $ticket->Load( $id );
+        ok( $id, "load ticket" ) or diag( "error: $msg" );
+
+        ($status, $msg) = $ticket->AddWatcher( Type => "AdminCc", PrincipalId => $user->id );
+        ok( $status, "AdminCC successfuly added") or diag( "error: $msg" );
+
+        my $member = $ticket->AdminCc->MembersObj->First;
+        my $shredder = $test->shredder_new();
+        $shredder->PutObjects( Objects => $member );
+        $shredder->WipeoutAll();
+        $test->db_is_valid;
+
+        $shredder->PutObjects( Objects => $user );
+        $shredder->WipeoutAll();
         $test->db_is_valid;
 }
 
 ### deleting member of the ticket Owner role group
 {
-	$test->restore_savepoint('clean');
-
-	my $user = RT::User->new( RT->SystemUser );
-	my ($uid, $msg) = $user->Create( Name => 'new user', Privileged => 1, Disabled => 0 );
-	ok( $uid, "created new user" ) or diag "error: $msg";
-	is( $user->id, $uid, "id is correct" );
-
-	use RT::Queue;
-	my $queue = RT::Queue->new( RT->SystemUser );
-	$queue->Load('general');
-	ok( $queue->id, "queue loaded succesfully" );
-
-	$user->PrincipalObj->GrantRight( Right => 'OwnTicket', Object => $queue );
-
-	use RT::Tickets;
-	my $ticket = RT::Ticket->new( RT->SystemUser );
-	my ($id) = $ticket->Create( Subject => 'test', Queue => $queue->id );
-	ok( $id, "created new ticket" );
-	$ticket = RT::Ticket->new( RT->SystemUser );
-	my $status;
-	($status, $msg) = $ticket->Load( $id );
-	ok( $id, "load ticket" ) or diag( "error: $msg" );
-
-	($status, $msg) = $ticket->SetOwner( $user->id );
-	ok( $status, "owner successfuly set") or diag( "error: $msg" );
-	is( $ticket->Owner, $user->id, "owner successfuly set") or diag( "error: $msg" );
-
-	my $member = $ticket->OwnerGroup->MembersObj->First;
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $member );
-	$shredder->WipeoutAll();
-	$test->db_is_valid;
-
-	$ticket = RT::Ticket->new( RT->SystemUser );
-	($status, $msg) = $ticket->Load( $id );
-	ok( $id, "load ticket" ) or diag( "error: $msg" );
-	is( $ticket->Owner, RT->Nobody->id, "owner switched back to nobody" );
-	is( $ticket->OwnerGroup->MembersObj->First->MemberId, RT->Nobody->id, "and owner role group member is nobody");
+        $test->restore_savepoint('clean');
+
+        my $user = RT::User->new( RT->SystemUser );
+        my ($uid, $msg) = $user->Create( Name => 'new user', Privileged => 1, Disabled => 0 );
+        ok( $uid, "created new user" ) or diag "error: $msg";
+        is( $user->id, $uid, "id is correct" );
+
+        use RT::Queue;
+        my $queue = RT::Queue->new( RT->SystemUser );
+        $queue->Load('general');
+        ok( $queue->id, "queue loaded succesfully" );
+
+        $user->PrincipalObj->GrantRight( Right => 'OwnTicket', Object => $queue );
+
+        use RT::Tickets;
+        my $ticket = RT::Ticket->new( RT->SystemUser );
+        my ($id) = $ticket->Create( Subject => 'test', Queue => $queue->id );
+        ok( $id, "created new ticket" );
+        $ticket = RT::Ticket->new( RT->SystemUser );
+        my $status;
+        ($status, $msg) = $ticket->Load( $id );
+        ok( $id, "load ticket" ) or diag( "error: $msg" );
+
+        ($status, $msg) = $ticket->SetOwner( $user->id );
+        ok( $status, "owner successfuly set") or diag( "error: $msg" );
+        is( $ticket->Owner, $user->id, "owner successfuly set") or diag( "error: $msg" );
+
+        my $member = $ticket->OwnerGroup->MembersObj->First;
+        my $shredder = $test->shredder_new();
+        $shredder->PutObjects( Objects => $member );
+        $shredder->WipeoutAll();
+        $test->db_is_valid;
+
+        $ticket = RT::Ticket->new( RT->SystemUser );
+        ($status, $msg) = $ticket->Load( $id );
+        ok( $id, "load ticket" ) or diag( "error: $msg" );
+        is( $ticket->Owner, RT->Nobody->id, "owner switched back to nobody" );
+        is( $ticket->OwnerGroup->MembersObj->First->MemberId, RT->Nobody->id, "and owner role group member is nobody");
 }
diff --git a/t/shredder/02queue.t b/t/shredder/02queue.t
index 00213ec..0c65c5d 100644
--- a/t/shredder/02queue.t
+++ b/t/shredder/02queue.t
@@ -8,21 +8,21 @@ my $test = "RT::Test::Shredder";
 
 diag 'simple queue' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $queue = RT::Queue->new( RT->SystemUser );
     my ($id, $msg) = $queue->Create( Name => 'my queue' );
     ok($id, 'created queue') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $queue );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $queue );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 diag 'queue with scrip' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $queue = RT::Queue->new( RT->SystemUser );
     my ($id, $msg) = $queue->Create( Name => 'my queue' );
     ok($id, 'created queue') or diag "error: $msg";
@@ -37,16 +37,16 @@ diag 'queue with scrip' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'created scrip') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $queue );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $queue );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 diag 'queue with template' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $queue = RT::Queue->new( RT->SystemUser );
     my ($id, $msg) = $queue->Create( Name => 'my queue' );
     ok($id, 'created queue') or diag "error: $msg";
@@ -59,16 +59,16 @@ diag 'queue with template' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'created template') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $queue );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $queue );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 diag 'queue with a right granted' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $queue = RT::Queue->new( RT->SystemUser );
     my ($id, $msg) = $queue->Create( Name => 'my queue' );
     ok($id, 'created queue') or diag "error: $msg";
@@ -83,22 +83,22 @@ diag 'queue with a right granted' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'granted right') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $queue );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $queue );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 diag 'queue with a watcher' if $ENV{TEST_VERBOSE};
 {
 # XXX, FIXME: if uncomment these lines then we'll get 'Bizarre...'
-#	$test->create_savepoint('clean');
+#    $test->create_savepoint('clean');
     my $group = RT::Group->new( RT->SystemUser );
     my ($id, $msg) = $group->CreateUserDefinedGroup(Name => 'my group');
     ok($id, 'created group') or diag "error: $msg";
 
-	$test->create_savepoint('bqcreate');
+    $test->create_savepoint('bqcreate');
     my $queue = RT::Queue->new( RT->SystemUser );
     ($id, $msg) = $queue->Create( Name => 'my queue' );
     ok($id, 'created queue') or diag "error: $msg";
@@ -109,13 +109,13 @@ diag 'queue with a watcher' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'added watcher') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $queue );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('bqcreate'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $queue );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('bqcreate'), "current DB equal to savepoint");
 
-#	$shredder->PutObjects( Objects => $group );
-#	$shredder->WipeoutAll;
-#	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+#    $shredder->PutObjects( Objects => $group );
+#    $shredder->WipeoutAll;
+#    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
diff --git a/t/shredder/02template.t b/t/shredder/02template.t
index 27c9bac..56dd852 100644
--- a/t/shredder/02template.t
+++ b/t/shredder/02template.t
@@ -8,7 +8,7 @@ my $test = "RT::Test::Shredder";
 
 diag 'global template' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $template = RT::Template->new( RT->SystemUser );
     my ($id, $msg) = $template->Create(
         Name => 'my template',
@@ -16,16 +16,16 @@ diag 'global template' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'created template') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $template );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $template );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 diag 'local template' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $template = RT::Template->new( RT->SystemUser );
     my ($id, $msg) = $template->Create(
         Name => 'my template',
@@ -34,16 +34,16 @@ diag 'local template' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'created template') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $template );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $template );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
 
 diag 'template used in scrip' if $ENV{TEST_VERBOSE};
 {
-	$test->create_savepoint('clean');
+    $test->create_savepoint('clean');
     my $template = RT::Template->new( RT->SystemUser );
     my ($id, $msg) = $template->Create(
         Name => 'my template',
@@ -62,9 +62,9 @@ diag 'template used in scrip' if $ENV{TEST_VERBOSE};
     );
     ok($id, 'created scrip') or diag "error: $msg";
 
-	my $shredder = $test->shredder_new();
-	$shredder->PutObjects( Objects => $template );
-	$shredder->WipeoutAll;
-	$test->db_is_valid;
-	cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
+    my $shredder = $test->shredder_new();
+    $shredder->PutObjects( Objects => $template );
+    $shredder->WipeoutAll;
+    $test->db_is_valid;
+    cmp_deeply( $test->dump_current_and_savepoint('clean'), "current DB equal to savepoint");
 }
diff --git a/t/shredder/02user.t b/t/shredder/02user.t
index 0aa80ee..620c2c5 100644
--- a/t/shredder/02user.t
+++ b/t/shredder/02user.t
@@ -28,7 +28,7 @@ $test->create_savepoint('aucreate'); # after user create
 {
     my $resolver = sub {
         my %args = (@_);
-        my $t =	$args{'TargetObject'};
+        my $t = $args{'TargetObject'};
         my $resolver_uid = RT->SystemUser->id;
         foreach my $method ( qw(Creator LastUpdatedBy) ) {
             next unless $t->_Accessible( $method => 'read' );
diff --git a/t/ticket/add-watchers.t b/t/ticket/add-watchers.t
index 11b3a84..37a04c7 100644
--- a/t/ticket/add-watchers.t
+++ b/t/ticket/add-watchers.t
@@ -15,7 +15,7 @@ my $acl = RT::ACL->new(RT->SystemUser);
 $acl->Limit( FIELD => 'RightName', OPERATOR => '!=', VALUE => 'SuperUser' );
 $acl->LimitToObject( RT->System );
 while( my $ace = $acl->Next ) {
-	$ace->Delete;
+    $ace->Delete;
 }
 
 # create new queue to be sure we do not mess with rights
@@ -25,11 +25,12 @@ ok( $queue_id, 'queue created for watcher tests' );
 
 # new privileged user to check rights
 my $user = RT::User->new( RT->SystemUser );
-my ($user_id) = $user->Create( Name => 'watcher'.$$,
-			   EmailAddress => "watcher$$".'@localhost',
-			   Privileged => 1,
-			   Password => 'qwe123',
-			 );
+my ($user_id) = $user->Create(
+    Name => 'watcher'.$$,
+    EmailAddress => "watcher$$".'@localhost',
+    Privileged => 1,
+    Password => 'qwe123',
+);
 my $cu= RT::CurrentUser->new($user);
 
 # make sure user can see tickets in the queue
diff --git a/t/web/custom_search.t b/t/web/custom_search.t
index bf7d659..75f832d 100644
--- a/t/web/custom_search.t
+++ b/t/web/custom_search.t
@@ -11,7 +11,7 @@ my $url = $m->rt_base_url;
 
 my $t = RT::Ticket->new(RT->SystemUser);
 $t->Create(Subject => 'for custom search'.$$, Queue => 'general',
-	   Owner => 'root', Requestor => 'customsearch at localhost');
+           Owner => 'root', Requestor => 'customsearch at localhost');
 ok(my $id = $t->id, 'created ticket for custom search');
 
 ok $m->login, 'logged in';
diff --git a/t/web/dashboards-basics.t b/t/web/dashboards-basics.t
index cd9f040..c3533a3 100644
--- a/t/web/dashboards-basics.t
+++ b/t/web/dashboards-basics.t
@@ -132,9 +132,9 @@ like($searches[1]->Name, qr/highest priority tickets I own/, "correct new search
 my $ticket = RT::Ticket->new(RT->SystemUser);
 $ticket->Create(
     Queue     => $queue->Id,
-	Requestor => [ $user_obj->Name ],
-	Owner     => $user_obj,
-	Subject   => 'dashboard test',
+    Requestor => [ $user_obj->Name ],
+    Owner     => $user_obj,
+    Subject   => 'dashboard test',
 );
 
 $m->follow_link_ok({id => 'page-show'});
diff --git a/t/web/rights1.t b/t/web/rights1.t
index 63ddb38..94d0e8c 100644
--- a/t/web/rights1.t
+++ b/t/web/rights1.t
@@ -29,9 +29,9 @@ $agent->login( $user_obj->Name, 'customer');
 
 # Test for absence of Configure and Preferences tabs.
 ok(!$agent->find_link( url => "$RT::WebPath/Admin/",
-		       text => 'Configuration'), "No config tab" );
+                       text => 'Configuration'), "No config tab" );
 ok(!$agent->find_link( url => "$RT::WebPath/User/Prefs.html",
-		       text => 'Preferences'), "No prefs pane" );
+                       text => 'Preferences'), "No prefs pane" );
 
 # Now test for their presence, one at a time.  Sleep for a bit after
 # ACL changes, thanks to the 10s ACL cache.
@@ -43,20 +43,20 @@ $agent->reload;
 
 $agent->content_contains('Logout', "Reloaded page successfully");
 ok($agent->find_link( url => "$RT::WebPath/Admin/",
-		       text => 'Configuration'), "Found config tab" );
+                       text => 'Configuration'), "Found config tab" );
 my ($revokeid,$revokemsg) =$user_obj->PrincipalObj->RevokeRight(Right => 'ShowConfigTab');
 ok ($revokeid,$revokemsg);
 ($grantid,$grantmsg) =$user_obj->PrincipalObj->GrantRight(Right => 'ModifySelf');
 ok ($grantid,$grantmsg);
 $agent->reload();
 $agent->content_contains('Logout', "Reloaded page successfully");
-ok($agent->find_link( 
-		       id => 'preferences-settings' ), "Found prefs pane" );
+ok($agent->find_link(
+                       id => 'preferences-settings' ), "Found prefs pane" );
 ($revokeid,$revokemsg) = $user_obj->PrincipalObj->RevokeRight(Right => 'ModifySelf');
 ok ($revokeid,$revokemsg);
 # Good.  Now load the search page and test Load/Save Search.
 $agent->follow_link( url => "$RT::WebPath/Search/Build.html",
-		     text => 'Tickets');
+                     text => 'Tickets');
 is($agent->status, 200, "Fetched search builder page");
 $agent->content_lacks("Load saved search", "No search loading box");
 $agent->content_lacks("Saved searches", "No saved searches box");
@@ -79,23 +79,23 @@ $agent->content_like(qr/input\s+type=['"]submit['"][^>]+name=['"]SavedSearchSave
 # via SelectOwner.
 
 my $queue_obj = RT::Queue->new(RT->SystemUser);
-($ret, $msg) = $queue_obj->Create(Name => 'CustomerQueue-'.$$, 
-				  Description => 'queue for SelectOwner testing');
+($ret, $msg) = $queue_obj->Create(Name => 'CustomerQueue-'.$$,
+                                  Description => 'queue for SelectOwner testing');
 ok($ret, "SelectOwner test queue creation. $msg");
 my $group_obj = RT::Group->new(RT->SystemUser);
 ($ret, $msg) = $group_obj->CreateUserDefinedGroup(Name => 'CustomerGroup-'.$$,
-			      Description => 'group for SelectOwner testing');
+                              Description => 'group for SelectOwner testing');
 ok($ret, "SelectOwner test group creation. $msg");
 
 # Add our customer to the customer group, and give it queue rights.
 ($ret, $msg) = $group_obj->AddMember($user_obj->PrincipalObj->Id());
 ok($ret, "Added customer to its group. $msg");
 ($grantid,$grantmsg) =$group_obj->PrincipalObj->GrantRight(Right => 'OwnTicket',
-				     Object => $queue_obj);
-                                     
+                                     Object => $queue_obj);
+
 ok($grantid,$grantmsg);
 ($grantid,$grantmsg) =$group_obj->PrincipalObj->GrantRight(Right => 'SeeQueue',
-				     Object => $queue_obj);
+                                     Object => $queue_obj);
 ok ($grantid,$grantmsg);
 # Now.  When we look at the search page we should be able to see
 # ourself in the list of possible owners.
diff --git a/t/web/search_simple.t b/t/web/search_simple.t
index a1a3ce8..d7c4727 100644
--- a/t/web/search_simple.t
+++ b/t/web/search_simple.t
@@ -44,14 +44,14 @@ my $t = RT::Ticket->new(RT->SystemUser);
 {
   my ($status, $msg) = $t->AddCustomFieldValue(
                            Field => $cf1->id,
-			   Value => 'Downtown');
+                           Value => 'Downtown');
   ok( $status, "Added CF value - $msg" );
 }
 
 {
   my ($status, $msg) = $t->AddCustomFieldValue(
                            Field => $cf2->id,
-			   Value => 'Proxy');
+                           Value => 'Proxy');
   ok( $status, "Added CF value - $msg" );
 }
 

commit 3c2a5621099712d488b2f524ebf3e4c9131f92e1
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Mon Jan 14 20:27:33 2013 -0500

    Replace hard tabs with \t in test strings

diff --git a/t/mail/mime_decoding.t b/t/mail/mime_decoding.t
index 4b3e3c0..c8679d1 100644
--- a/t/mail/mime_decoding.t
+++ b/t/mail/mime_decoding.t
@@ -87,7 +87,7 @@ inline;
 diag q{canonicalize mime word encodings like gb2312};
 {
     my $str = qq{Subject: =?gb2312?B?1NrKwL3nuPe12Lmy09CzrN9eX1NpbXBsaWZpZWRfQ05fR0IyMzEyYQ==?=
-	=?gb2312?B?dHRhY2hlbWVudCB0ZXN0IGluIENOIHNpbXBsaWZpZWQ=?=};
+\t=?gb2312?B?dHRhY2hlbWVudCB0ZXN0IGluIENOIHNpbXBsaWZpZWQ=?=};
 
     is(
         RT::I18N::DecodeMIMEWordsToUTF8($str),
diff --git a/t/mail/outlook.t b/t/mail/outlook.t
index 9c7e715..8f3b71b 100644
--- a/t/mail/outlook.t
+++ b/t/mail/outlook.t
@@ -15,11 +15,11 @@ X-Mailer: $mailer
 To: rt\@@{[RT->Config->Get('rtname')]}
 Subject: outlook basic test
 Content-Type: multipart/alternative;
-	boundary="----=_NextPart_000_0004_01CB045C.A5A075D0"
+\tboundary="----=_NextPart_000_0004_01CB045C.A5A075D0"
 
 ------=_NextPart_000_0004_01CB045C.A5A075D0
 Content-Type: text/plain;
-	charset="us-ascii"
+\tcharset="us-ascii"
 Content-Transfer-Encoding: 7bit
 
 here is the content
@@ -33,7 +33,7 @@ another line
 
 ------=_NextPart_000_0004_01CB045C.A5A075D0
 Content-Type: text/html;
-	charset="us-ascii"
+\tcharset="us-ascii"
 Content-Transfer-Encoding: quoted-printable
 
 <html>this is fake</html>
@@ -61,16 +61,16 @@ X-Mailer: $mailer
 To: rt\@@{[RT->Config->Get('rtname')]}
 Subject: outlook basic test
 Content-Type: multipart/mixed;
-	boundary="----=_NextPart_000_000F_01CB045E.5222CB40"
+\tboundary="----=_NextPart_000_000F_01CB045E.5222CB40"
 
 ------=_NextPart_000_000F_01CB045E.5222CB40
 Content-Type: multipart/alternative;
-	boundary="----=_NextPart_001_0010_01CB045E.5222CB40"
+\tboundary="----=_NextPart_001_0010_01CB045E.5222CB40"
 
 
 ------=_NextPart_001_0010_01CB045E.5222CB40
 Content-Type: text/plain;
-	charset="us-ascii"
+\tcharset="us-ascii"
 Content-Transfer-Encoding: 7bit
 
 foo
@@ -84,7 +84,7 @@ baz
 
 ------=_NextPart_001_0010_01CB045E.5222CB40
 Content-Type: text/html;
-	charset="us-ascii"
+\tcharset="us-ascii"
 Content-Transfer-Encoding: quoted-printable
 
 <html>this is fake</html>
@@ -93,10 +93,10 @@ Content-Transfer-Encoding: quoted-printable
 
 ------=_NextPart_000_000F_01CB045E.5222CB40
 Content-Type: text/plain;
-	name="att.txt"
+\tname="att.txt"
 Content-Transfer-Encoding: quoted-printable
 Content-Disposition: attachment;
-	filename="att.txt"
+\tfilename="att.txt"
 
 this is the attachment! :)=0A=
 
@@ -223,11 +223,11 @@ X-Mailer: Mutt
 To: rt\@@{[RT->Config->Get('rtname')]}
 Subject: outlook basic test
 Content-Type: multipart/alternative;
-	boundary="----=_NextPart_000_0004_01CB045C.A5A075D0"
+\tboundary="----=_NextPart_000_0004_01CB045C.A5A075D0"
 
 ------=_NextPart_000_0004_01CB045C.A5A075D0
 Content-Type: text/plain;
-	charset="us-ascii"
+\tcharset="us-ascii"
 Content-Transfer-Encoding: 7bit
 
 foo
@@ -241,7 +241,7 @@ baz
 
 ------=_NextPart_000_0004_01CB045C.A5A075D0
 Content-Type: text/html;
-	charset="us-ascii"
+\tcharset="us-ascii"
 Content-Transfer-Encoding: quoted-printable
 
 <html>this is fake</html>

commit 07273951d61a15a049316d1ffbb384e060f87226
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Mon Jan 14 20:30:45 2013 -0500

    Add a policy test to enforce lack of tabs for BPS files

diff --git a/t/99-policy.t b/t/99-policy.t
index 35b5cc6..5994a6b 100644
--- a/t/99-policy.t
+++ b/t/99-policy.t
@@ -22,6 +22,7 @@ sub check {
     my %check = (
         strict   => 0,
         warnings => 0,
+        no_tabs  => 0,
         shebang  => 0,
         exec     => 0,
         bps_tag  => 0,
@@ -29,7 +30,7 @@ sub check {
         @_,
     );
 
-    if ($check{strict} or $check{warnings} or $check{shebang} or $check{bps_tag}) {
+    if ($check{strict} or $check{warnings} or $check{shebang} or $check{bps_tag} or $check{no_tabs}) {
         local $/;
         open my $fh, '<', $file or die $!;
         my $content = <$fh>;
@@ -64,6 +65,10 @@ sub check {
         } elsif ($check{bps_tag} == -1) {
             unlike( $content, qr/[B]EGIN BPS TAGGED BLOCK {{{/, "$file has no BPS license tag");
         }
+
+        if ($check{bps_tag} != -1 and $check{no_tabs}) {
+            unlike( $content, qr/\t/, "$file has no hard tabs" );
+        }
     }
 
     my $executable = ( stat $file )[2] & 0100;
@@ -87,22 +92,22 @@ sub check {
     }
 }
 
-check( $_, shebang => -1, exec => -1, warnings => 1, strict => 1, bps_tag => 1 )
+check( $_, shebang => -1, exec => -1, warnings => 1, strict => 1, bps_tag => 1, no_tabs => 1 )
     for grep {m{^lib/.*\.pm$}} @files;
 
-check( $_, shebang => -1, exec => -1, warnings => 1, strict => 1, bps_tag => -1 )
+check( $_, shebang => -1, exec => -1, warnings => 1, strict => 1, bps_tag => -1, no_tabs => 1 )
     for grep {m{^t/.*\.t$}} @files;
 
-check( $_, shebang => 1, exec => 1, warnings => 1, strict => 1, bps_tag => 1 )
+check( $_, shebang => 1, exec => 1, warnings => 1, strict => 1, bps_tag => 1, no_tabs => 1 )
     for grep {m{^s?bin/}} @files;
 
-check( $_, shebang => 1, exec => 1, warnings => 1, strict => 1, bps_tag => 1 )
+check( $_, shebang => 1, exec => 1, warnings => 1, strict => 1, bps_tag => 1, no_tabs => 1 )
     for grep {m{^devel/tools/} and not m{/(localhost\.(crt|key)|mime\.types)$}} @files;
 
 check( $_, exec => -1 )
     for grep {m{^share/static/}} @files;
 
-check( $_, exec => -1, bps_tag => 1 )
+check( $_, exec => -1, bps_tag => 1, no_tabs => 1 )
     for grep {m{^share/html/}} @files;
 
 check( $_, exec => -1 )
@@ -111,5 +116,5 @@ check( $_, exec => -1 )
 check( $_, exec => -1 )
     for grep {m{^t/data/}} @files;
 
-check( $_, warnings => 1, strict => 1, compile => 1 )
+check( $_, warnings => 1, strict => 1, compile => 1, no_tabs => 1 )
     for grep {m{^etc/upgrade/.*/content$}} @files;

-----------------------------------------------------------------------


More information about the Rt-commit mailing list