more useful options | |
PerlMonks |
Re^3: undef is undefby moritz (Cardinal) |
on Aug 29, 2012 at 10:11 UTC ( [id://990426]=note: print w/replies, xml ) | Need Help?? |
Adding accessor to usr sounds like a wise solution to hide test ifs, but it will mask the fact that avatar is accessor of person. Hiding unneeded facts is what abstraction is all about. Why should a user of your backend model care about which table the avatar comes from? If the user doesn't have to care, it means you can change that stuff later on the in the database and only adapt your model, not your code that generates the HTML.
In Section
Seekers of Perl Wisdom
|
|