Skip to main content

adoptable

Function adoptable 

Source
fn adoptable(stored: &[u8]) -> Result<Option<(&'_ UserId, &'_ DeviceId)>>
Expand description

Reads a stored token value, yielding its owner only when the row is one this pass may annotate.

A foreign row omits the trailing expiry field and reads as None. This server always writes that field, even empty, so every row it wrote encodes shorter than it is stored. The length comparison is what skips a token issued here after the import, whose foreign expiry no longer describes it.