Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Re: [ridesworld] bug in dir Converter

Quote Reply
Re: [ridesworld] bug in dir Converter In reply to
Ok, sorry I noticed some potential problems that I feel need pointing out. Here goes:

1) "use lib" is used in the perl module but it isn't needed.

2) Data::Dumper debugging code is left in the code. That's not a major issue but it is loading a module that isn't needed. The reason for pointing this out too is that GT::Dumper is a better option for compatiblity sake (yes I know DAta::Dumper is standard but still).

3) Excessive use of "my" at the top. my() is actually a sub-routine so there about 13 sub-routine calls when this could be reduced to one or two by declaring more than one variable at once.

4) "not" used where "!" would be more appropriate.

5) Unnecessary escaping of single quotes inside qq||

6) Incorrect use of "ne" when comparing numerics. Should use "!="

7) Incorrect use of eq when comparing numerics. Should use "=="

8) Unnecessary use of parenthesis in regexes when no capturing is needed (this affects speed).

9) Escpaing of forward slashes in regexes could be avoided by changing the substitution delimiter.

10) Use of my() outside a sub-routine (thanks Yogi).

That's it for now - there may be other things I've missed. I think the plugin would fail under mod_perl.

This is intended as constructive criticizm.

Last edited by:

Paul: Mar 12, 2003, 8:51 AM
Subject Author Views Date
Thread; hot thread bug in dir Converter ridesworld 9972 Mar 12, 2003, 8:07 AM
Post; hot thread Re: [ridesworld] bug in dir Converter
Andy 9664 Mar 12, 2003, 8:17 AM
Thread; hot thread Re: [ridesworld] bug in dir Converter
Paul 9687 Mar 12, 2003, 8:47 AM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 9556 Mar 13, 2003, 4:55 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7275 Mar 13, 2003, 5:15 AM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7280 Mar 13, 2003, 7:07 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7282 Mar 13, 2003, 7:14 AM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7195 Mar 13, 2003, 8:13 AM
Post; hot thread Re: [webmaster33] bug in dir Converter
klauslovgreen 7212 Mar 13, 2003, 8:40 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7254 Mar 13, 2003, 9:03 AM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7646 Mar 13, 2003, 9:29 AM
Post; hot thread Re: [webmaster33] bug in dir Converter
Paul 7204 Mar 13, 2003, 9:32 AM
Thread; hot thread Re: [ridesworld] bug in dir Converter
webmaster33 9692 Mar 12, 2003, 10:12 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
ridesworld 9675 Mar 12, 2003, 12:29 PM
Thread; hot thread Re: [ridesworld] bug in dir Converter
Paul 9781 Mar 12, 2003, 12:48 PM
Post; hot thread Re: [Paul] bug in dir Converter
webmaster33 9605 Mar 12, 2003, 1:08 PM
Thread; hot thread Re: [ridesworld] bug in dir Converter
webmaster33 9677 Mar 12, 2003, 1:11 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
yogi 9697 Mar 12, 2003, 1:19 PM
Thread; hot thread Re: [yogi] bug in dir Converter
Paul 9640 Mar 12, 2003, 1:26 PM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 9629 Mar 12, 2003, 1:54 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 9610 Mar 12, 2003, 2:10 PM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 9673 Mar 12, 2003, 2:22 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 9626 Mar 12, 2003, 2:27 PM
Post; hot thread Re: [Paul] bug in dir Converter
webmaster33 9563 Mar 12, 2003, 2:37 PM
Thread; hot thread Re: [yogi] bug in dir Converter
webmaster33 9610 Mar 12, 2003, 2:47 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
yogi 9627 Mar 12, 2003, 2:51 PM
Thread; hot thread Re: [yogi] bug in dir Converter
webmaster33 9629 Mar 12, 2003, 2:57 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 9633 Mar 12, 2003, 3:19 PM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 9616 Mar 12, 2003, 4:43 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
ridesworld 9688 Mar 13, 2003, 2:33 AM
Thread; hot thread Re: [ridesworld] bug in dir Converter
Paul 9595 Mar 13, 2003, 3:21 AM
Post; hot thread Re: [Paul] bug in dir Converter
webmaster33 9545 Mar 13, 2003, 3:35 AM
Post; hot thread Re: [ridesworld] bug in dir Converter
webmaster33 9518 Mar 13, 2003, 3:36 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7249 Mar 13, 2003, 5:31 AM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7260 Mar 13, 2003, 7:02 AM
Post; hot thread Re: [webmaster33] bug in dir Converter
Paul 7227 Mar 13, 2003, 7:07 AM
Thread; hot thread Re: [ridesworld] bug in dir Converter
webmaster33 7226 Mar 29, 2003, 10:00 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
cwi 7149 Mar 29, 2003, 10:07 AM
Thread; hot thread Re: [cwi] bug in dir Converter
webmaster33 7171 Mar 29, 2003, 10:15 AM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7181 Mar 29, 2003, 11:20 AM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7167 Mar 29, 2003, 12:13 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7196 Mar 29, 2003, 12:37 PM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7195 Mar 29, 2003, 1:09 PM
Thread; hot thread Re: [webmaster33] bug in dir Converter
Paul 7179 Mar 29, 2003, 1:15 PM
Thread; hot thread Re: [Paul] bug in dir Converter
webmaster33 7154 Mar 29, 2003, 1:20 PM
Post; hot thread Re: [webmaster33] bug in dir Converter
Paul 7110 Mar 29, 2003, 1:21 PM