Our Personal Data Server from scratch!
0

Configure Feed

Select the types of activity you want to include in your feed.

types: drop unchecked construction from validated newtypes

Lewis: May this revision serve well! <lu5a@proton.me>

author
Lewis
date (Jul 24, 2026, 8:45 PM +0300) commit 185b2100 parent 5a4aac37 change-id lxowmwtv
+12 -6
+12 -6
crates/tranquil-types/src/lib.rs
··· 42 42 } 43 43 } 44 44 45 - impl From<String> for $name { 46 - fn from(s: String) -> Self { 47 - Self(s) 48 - } 49 - } 50 - 51 45 impl<'a> From<&'a $name> for Cow<'a, str> { 52 46 fn from(val: &'a $name) -> Self { 53 47 Cow::Borrowed(&val.0) ··· 109 103 } 110 104 } 111 105 106 + impl From<String> for $name { 107 + fn from(s: String) -> Self { 108 + Self(s) 109 + } 110 + } 111 + 112 112 impl_string_common!($name); 113 113 }; 114 114 } ··· 126 126 impl $name { 127 127 pub fn new(s: impl Into<String>) -> Self { 128 128 Self(s.into()) 129 + } 130 + } 131 + 132 + impl From<String> for $name { 133 + fn from(s: String) -> Self { 134 + Self(s) 129 135 } 130 136 } 131 137