Conditions | 3 |
Paths | 4 |
Total Lines | 26 |
Code Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
16 | public function run() |
||
17 | { |
||
18 | global $opt; |
||
19 | |||
20 | if ($opt['logic']['logs']['purge_email'] > 0) { |
||
21 | sql( |
||
22 | 'DELETE FROM `email_user` WHERE date_created < NOW() - INTERVAL &1 DAY', |
||
23 | $opt['logic']['logs']['purge_email'] |
||
24 | ); |
||
25 | sql( |
||
26 | 'DELETE FROM `logentries` WHERE date_created < NOW() - INTERVAL &1 DAY AND eventid IN (1,2,3,8)', |
||
27 | $opt['logic']['logs']['purge_email'] |
||
28 | ); |
||
29 | } |
||
30 | |||
31 | if ($opt['logic']['logs']['purge_userdata'] > 0) { |
||
32 | sql( |
||
33 | "DELETE FROM `logentries` WHERE date_created < NOW() - `INTERVAL` &1 DAY AND eventid IN (6,7)", |
||
34 | $opt['logic']['logs']['purge_userdata'] |
||
35 | ); |
||
36 | } |
||
37 | |||
38 | // Type 5 events = adoptions are still recorded here and preliminary archived, |
||
39 | // but may be discarded after verifying that they are not used anywhere. |
||
40 | // Adoptions are now in cache_adoptions table. |
||
41 | } |
||
42 | } |
||
43 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.