Added MAYBE Function and some code fixes.