/[A3C]/lib/A3C/Model/StrixInstanceSelection.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /lib/A3C/Model/StrixInstanceSelection.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 157 by dpavlin, Sun Jun 15 10:51:57 2008 UTC revision 158 by dpavlin, Sun Jun 15 11:03:50 2008 UTC
# Line 39  sub validate_strix { Line 39  sub validate_strix {
39    
40  sub current_user_can {  sub current_user_can {
41          my $self = shift;          my $self = shift;
42  #       warn " current_user->id: ", $self->current_user->id, " == ", dump( $self->by_user->id );          my $op = shift;
43          # FIXME just my sites  
44          #return 1 if $self->by_user->id == $self->current_user->id;          if ( $op eq 'create' ) {
45          return 1;                  my %args = @_;
46                    return 1 if $args{by_user} == $self->current_user->id;
47            }
48    
49            return 1 if $self->by_user->id == $self->current_user->id;
50    
51          return 0;          return 0;
52  }  }
53    

Legend:
Removed from v.157  
changed lines
  Added in v.158

  ViewVC Help
Powered by ViewVC 1.1.26