/[smecontribs]/rpms/smeserver-mailsorting/contribs9/smeserver-mailsorting-1.4.bz10366.respectGeekmode.patch
ViewVC logotype

Annotation of /rpms/smeserver-mailsorting/contribs9/smeserver-mailsorting-1.4.bz10366.respectGeekmode.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Tue Jul 4 18:07:11 2017 UTC (6 years, 10 months ago) by unnilennium
Branch: MAIN
CVS Tags: smeserver-mailsorting-1_4-9_el6_sme, smeserver-mailsorting-1_4-10_el6_sme, HEAD
* Tue Jul 04 2017 Jean-Philipe Pialasse <tests@pialasse.com> 1.4-9.sme
- fix geekmode not honoured [SME: 10366]
- thanks to John Crisp for the fix.

1 unnilennium 1.1 diff -Nur smeserver-mailsorting-1.4.old/root/etc/e-smith/events/actions/mailsorting-update-user smeserver-mailsorting-1.4/root/etc/e-smith/events/actions/mailsorting-update-user
2     --- smeserver-mailsorting-1.4.old/root/etc/e-smith/events/actions/mailsorting-update-user 2014-12-02 01:32:45.000000000 -0500
3     +++ smeserver-mailsorting-1.4/root/etc/e-smith/events/actions/mailsorting-update-user 2017-07-04 13:49:59.584000000 -0400
4     @@ -41,7 +41,7 @@
5     "Account $userName is not a user account; update mailsorting failed.\n"
6     unless ($user && $user->prop('type') eq "user" || $userName eq "admin");
7     @users = ($user);
8     -my $geekmode = $user->prop('geekmode') || 'disabled';
9     + my $geekmode = $user->prop('geekmode') || 'disabled';
10     if($geekmode eq "enabled"){
11     print "User $userName in geek mode, do not update mailfilter and procmail rules.\n";
12     exit;
13     @@ -56,10 +56,16 @@
14     foreach my $userName (@users)
15     {
16     $userName = $userName->key;
17     + my $geekmode = $accountsdb->get_prop ($userName,'geekmode') || 'disabled';
18     + if ( $geekmode eq "enabled" )
19     + {
20     + print "User $userName in geek mode, do not update mailfilter and procmail rules.\n";
21     + next;
22     + }
23    
24     for my $dotfile ( qw(.procmailrc .mailfilter) )
25     {
26     -my $pathtohome = ($userName eq 'admin')? "/home/e-smith":"/home/e-smith/files/users/$userName";
27     + my $pathtohome = ($userName eq 'admin')? "/home/e-smith":"/home/e-smith/files/users/$userName";
28    
29     esmith::templates::processTemplate (
30     {

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed