fix: Add guards for converting Stat interface (might be nil)