Fixing random bugs. Example is now working.