Hey there, I'm Wynn!
I'm a front-end designer & developer, CSS & JavaScript framework fanboy Razorback living in Texas.
Featured
-
Recently
Archives
Links
The Changelog – Open Source moves fast. Keep up.- cartagen - Client side framework for creating vector maps in HTML5
- NoRM - Bringing MongoDB to .NET, LINQ, and Mono
- Episode 0.1.6 - Ajax.org frameworks with Ruben Daniels and Rik Arends
- Git clone some nostalgia - NCSA Mosiac
- Ghost means never having to touch /etc/hosts again
- Prism - command line and Ruby library parser for Microformats
- Pull! Skeet - Twitter Extension for Google Chrome
- QR - Easy Redis queues with Python
- Faye - dirt simple pub/sub for Rack and Node.js
- FOWA 2010: David Recordon on Facebook Open Source Projects






Quick tip: Use APIdock to hunt down missing methods
From time to time, we all to have step into older projects and add features. Suddenly that old standby method you’d come to love is giving you a
method_missing. How do you go about finding out which version of Rails introduced it so you can upgrade or monkey patch? APIdock has your back.I bring this up because all too many gems depend on Active Support from Rails and introducing a new gem into an older Rails project can lead to some headaches when Active Support versions collide.
A real world example
My LinkedIn gem depends on ROXML which in turn depends on Active Support, and more specifically
Object#present?. If you don’t knowpresent?is just the opposite ofblank?. Never one to eschew theunlessconditional (I know, I’m a heretic) I’ve always usedunless foo.blank?and didn’t notice whenpresent?was added.So when asked to debug my gem in an older project the error message was puzzling:
undefined method `present?' for "status":StringStringin this case is just a red herring. How do I know that? (Pretend for a minute you don’t usepresent?all the time or that you’re a noob). A quick search on APIdock tells us that Active Support added this method in version 2.2.1.I know this because the navigation is enabled for this method starting in 2.2.1. So, mystery solved. My friend can now monkey patch his way out of this one or upgrade to a later version of Active Support. Pick your poison.
No related posts.