(fromJust) replaced everywhere with (fromMaybe)