DrSkippy / Gnacs

Gnip normalized social data activities json to csv parser.
DrSkippy.github.io/Gnacs
Other
5 stars 11 forks source link

keypath addition #20

Closed blehman closed 10 years ago

DrSkippy commented 10 years ago

You had added the exact same code to all of the files. One of the reasons we design things the way we do in OO is to avoid this. The reason we want to avoid having repeated code (Fowler would call this a bad smell in the code) is that it is confusing to read the same code over and over but assume it is doing something different (otherwise, why is it repeated?) and it is risky to make changes to to the code because general changes need to be repeated in all of the instances of the code--but there isn't a good way to find all of the instances of repeated code. It is also somewhat difficult to find verify that all instances of repeated code chunks of this size are actually the same. Please move this code into the base class so that it appears only once.