Cleaned up loadData, using >>= and either