Fixed indentation & typos. Added test.