Use a try/catch block rather than method swizzling to handle undefined keys