Function read

Source
pub fn read(value: &Json) -> Found
Expand description

Reads what the service answered.

The synced form wins where there is one, because it is the richer of the two: crate::lyrics::parse reads it into lines that carry their timings, and a reader who only wants the words gets them from the same lines with the timings dropped. Taking the plain form when a timed one exists would throw away something that cannot be recovered.

A non-instrumental answer whose text is empty or only LRC metadata is Found::Nothing: a record with no words in it is not an answer about the words. Use read_checked at the network boundary to distinguish that from a malformed success body.