diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2011-12-01 05:27:04 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2011-12-01 05:27:04 +0000 |
commit | 2507fd1cd4448c4b0f03973e5961262472172ef7 (patch) | |
tree | 2a81c540a1f2ace691c7be5ebfdfd7eeb46e32a4 /extra | |
parent | 652fb58b2b0b45d55878a27afe7d9df8e5a3d741 (diff) | |
download | redmine-2507fd1cd4448c4b0f03973e5961262472172ef7.tar.gz redmine-2507fd1cd4448c4b0f03973e5961262472172ef7.zip |
remove trailing white-spaces except SQL from extra/svn/Redmine.pm
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8015 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'extra')
-rw-r--r-- | extra/svn/Redmine.pm | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/extra/svn/Redmine.pm b/extra/svn/Redmine.pm index fd019b402..31f204d8a 100644 --- a/extra/svn/Redmine.pm +++ b/extra/svn/Redmine.pm @@ -49,7 +49,7 @@ Authen::Simple::LDAP (and IO::Socket::SSL if LDAPS is used): PerlAccessHandler Apache::Authn::Redmine::access_handler PerlAuthenHandler Apache::Authn::Redmine::authen_handler - + ## for mysql RedmineDSN "DBI:mysql:database=databasename;host=my.db.server" ## for postgres @@ -144,7 +144,7 @@ my @directives = ( }, ); -sub RedmineDSN { +sub RedmineDSN { my ($self, $parms, $arg) = @_; $self->{RedmineDSN} = $arg; my $query = "SELECT @@ -164,12 +164,12 @@ sub RedmineDSN { sub RedmineDbUser { set_val('RedmineDbUser', @_); } sub RedmineDbPass { set_val('RedmineDbPass', @_); } -sub RedmineDbWhereClause { +sub RedmineDbWhereClause { my ($self, $parms, $arg) = @_; $self->{RedmineQuery} = trim($self->{RedmineQuery}.($arg ? $arg : "")." "); } -sub RedmineCacheCredsMax { +sub RedmineCacheCredsMax { my ($self, $parms, $arg) = @_; if ($arg) { $self->{RedmineCachePool} = APR::Pool->new; @@ -216,10 +216,10 @@ sub access_handler { sub authen_handler { my $r = shift; - + my ($res, $redmine_pass) = $r->get_basic_auth_pw(); return $res unless $res == OK; - + if (is_member($r->user, $redmine_pass, $r)) { return OK; } else { @@ -246,7 +246,7 @@ sub is_authentication_forced { } $sth->finish(); undef $sth; - + $dbh->disconnect(); undef $dbh; @@ -256,7 +256,7 @@ sub is_authentication_forced { sub is_public_project { my $project_id = shift; my $r = shift; - + if (is_authentication_forced($r)) { return 0; } @@ -283,12 +283,12 @@ sub is_public_project { sub anonymous_role_allows_browse_repository { my $r = shift; - + my $dbh = connect_database($r); my $sth = $dbh->prepare( "SELECT permissions FROM roles WHERE builtin = 2;" ); - + $sth->execute(); my $ret = 0; if (my @row = $sth->fetchrow_array) { @@ -300,7 +300,7 @@ sub anonymous_role_allows_browse_repository { undef $sth; $dbh->disconnect(); undef $dbh; - + $ret; } @@ -328,7 +328,7 @@ sub is_member { my $project_id = get_project_identifier($r); my $pass_digest = Digest::SHA1::sha1_hex($redmine_pass); - + my $access_mode = defined $read_only_methods{$r->method} ? "R" : "W"; my $cfg = Apache2::Module::get_config(__PACKAGE__, $r->server, $r->per_dir_config); @@ -397,7 +397,7 @@ sub is_member { sub get_project_identifier { my $r = shift; - + my $location = $r->location; my ($identifier) = $r->uri =~ m{$location/*([^/]+)}; $identifier; @@ -405,7 +405,7 @@ sub get_project_identifier { sub connect_database { my $r = shift; - + my $cfg = Apache2::Module::get_config(__PACKAGE__, $r->server, $r->per_dir_config); return DBI->connect($cfg->{RedmineDSN}, $cfg->{RedmineDbUser}, $cfg->{RedmineDbPass}); } |