{"id":104,"date":"2010-10-05T22:58:27","date_gmt":"2010-10-05T22:58:27","guid":{"rendered":"http:\/\/xphone.pt\/devnotes\/?p=104"},"modified":"2010-10-05T23:33:16","modified_gmt":"2010-10-05T23:33:16","slug":"how-i-killed-a-bug-on-my-published-app-without-touching-the-code","status":"publish","type":"post","link":"http:\/\/xphone.pt\/devnotes\/2010\/10\/how-i-killed-a-bug-on-my-published-app-without-touching-the-code\/","title":{"rendered":"How I &#8220;killed&#8221; a Bug on my published App without touching the code! ;-)"},"content":{"rendered":"<p>Hi!<\/p>\n<p>This post consists on just a little curiosity which I decided to share with you but, hopping that it will maybe make you think a little different, the next time you find a bug on your App&#8230;<\/p>\n<p>There has been almost 3 months since we launched <a title=\"SA2010SS\" href=\"http:\/\/xphone.me\/sa2010ss\/home.html\" target=\"_blank\"><strong>South Africa 2010 Soccer Scores<\/strong><\/a>.<\/p>\n<p>Today I was reviewing its code and doing some changes because our next planned app will be based on that. Then I was completely surprised when I discovered a little bug that nobody had reported neither we had never noticed!<\/p>\n<p>The little bug is that on the &#8220;About&#8221; tab of our App:<\/p>\n<div id=\"attachment_106\" style=\"width: 330px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/itunes.apple.com\/pt\/app\/south-africa-2010-soccer-scores\/id379206383?mt=8\" target=\"_blank\"><img aria-describedby=\"caption-attachment-106\" loading=\"lazy\" class=\"size-full wp-image-106   \" title=\"SA2010SS-About(marked)\" src=\"http:\/\/xphone.pt\/devnotes\/wp-content\/uploads\/2010\/10\/SA2010SS-Aboutmarked1.jpg\" alt=\"SA2010SS-About(marked)\" width=\"320\" height=\"480\" srcset=\"http:\/\/xphone.pt\/devnotes\/wp-content\/uploads\/2010\/10\/SA2010SS-Aboutmarked1.jpg 320w, http:\/\/xphone.pt\/devnotes\/wp-content\/uploads\/2010\/10\/SA2010SS-Aboutmarked1-200x300.jpg 200w\" sizes=\"(max-width: 320px) 100vw, 320px\" \/><\/a><p id=\"caption-attachment-106\" class=\"wp-caption-text\">SA2010SS - About screen tab<\/p><\/div>\n<p>the link that I marked with <span style=\"color: yellow;\">yellow<\/span> on the above screen-shot is <strong>WRONG!<\/strong><\/p>\n<p>Why is it wrong? Because it should link to: &#8220;<a href=\"http:\/\/xphone.me\/sa2010ss\" target=\"_blank\">http:\/\/xphone.me\/sa2010ss<\/a>&#8221; instead of &#8220;<a href=\"http:\/\/xphone.me\/wcs2010\" target=\"_blank\">http:\/\/xphone.me\/wcs2010<\/a>&#8220;.<\/p>\n<p>That happened for a reason that I&#8217;ll also share with you&#8230;<\/p>\n<p>The wrong link was because our original submitted App name was &#8220;World Cup Scores 2010&#8221; but due to the possibility of some FIFA legal copyright\/trademarks infringement with the expression &#8220;World Cup&#8221;, we had to change it at the last hour, to the final name &#8220;South Africa 2010 Soccer Scores&#8221;.<\/p>\n<p>In order to maintain the coherence we had also changed our original web page about that App, from the &#8220;<a href=\"http:\/\/xphone.me\/wcs2010\" target=\"_blank\">http:\/\/xphone.me\/wcs2010<\/a>&#8221; URL to the new one &#8220;<a href=\"http:\/\/xphone.me\/sa2010ss\" target=\"_blank\">http:\/\/xphone.me\/sa2010ss<\/a>&#8220;.<\/p>\n<p>Well it seems we updated all the image assets but we forgot that little link on the &#8220;About&#8221; tab!<\/p>\n<p>Today when I discovered it, the first thought on my head was to correct the code and update the App on the App Store. That would be simple but why should I do that if probably almost nobody will update this App since the World Cup had already finished quite a long time. Simple conclusion: it is not worth the effort!<\/p>\n<p>But because I don&#8217;t like to known that there are some living bugs on my code and I would like that if someone click on that link he\/she can reach our web page and not a blank error page, I thought a little more on this issue and then I realized, the solution was even simpler&#8230; I had just created a simple &#8220;index.html&#8221; page on &#8220;<a href=\"http:\/\/xphone.me\/wcs2010\" target=\"_blank\">http:\/\/xphone.me\/wcs2010<\/a>&#8221; that redirects the users the right page! And now the insect is killed! \ud83d\ude42<\/p>\n<p>Disclaimer: I have nothing against real bugs! \ud83d\ude09<\/p>\n<p>Well, this post doesn&#8217;t teach you anything special but I think it can give you an useful message:<\/p>\n<ul>\n<li><strong>the obvious solution is not always the best choice!<\/strong><\/li>\n<\/ul>\n<p><strong>&#8212;<br \/>\n<\/strong><\/p>\n<p>By the way, if you want to know a little more about <a title=\"SA2010SS on the App Store\" href=\"http:\/\/itunes.apple.com\/pt\/app\/south-africa-2010-soccer-scores\/id379206383?mt=8\" target=\"_blank\">SA2010SS<\/a>, read my old post: &#8220;<a title=\"My first iPhone App on the App Store! :-)\" href=\".\/2010\/07\/my-first-iphone-app-on-the-app-store\/\" target=\"_self\">My first iPhone App on the App Store! \ud83d\ude42<\/a>&#8220;.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hi! This post consists on just a little curiosity which I decided to share with you but, hopping that it will maybe make you think a little different, the next time you find a bug on your App&#8230; There has been almost 3 months since we launched South Africa 2010 Soccer Scores. Today I was [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[13,61,59],"tags":[34,19,35,25,3,4,11,9,10],"_links":{"self":[{"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/posts\/104"}],"collection":[{"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/comments?post=104"}],"version-history":[{"count":37,"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/posts\/104\/revisions"}],"predecessor-version":[{"id":143,"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/posts\/104\/revisions\/143"}],"wp:attachment":[{"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/media?parent=104"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/categories?post=104"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/xphone.pt\/devnotes\/wp-json\/wp\/v2\/tags?post=104"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}