added scope read_by, with tests. plus refactor for readability