File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -84,7 +84,13 @@ pub fn propvals_v1_to_v2(propvals: PropValsV1) -> crate::resources::PropVals {
84
84
impl From < SubResourceV1 > for crate :: values:: SubResource {
85
85
fn from ( sub_resource : SubResourceV1 ) -> Self {
86
86
match sub_resource {
87
- SubResourceV1 :: Resource ( _resource) => panic ! ( "ResourceV1 is not supported" ) ,
87
+ SubResourceV1 :: Resource ( resource) => {
88
+ tracing:: warn!(
89
+ "Named SubResource found, converting to Subject {}" ,
90
+ resource. subject
91
+ ) ;
92
+ return Self :: Subject ( resource. subject ) ;
93
+ }
88
94
SubResourceV1 :: Nested ( propvals) => Self :: Nested ( propvals_v1_to_v2 ( propvals) ) ,
89
95
SubResourceV1 :: Subject ( subject) => Self :: Subject ( subject) ,
90
96
}
@@ -115,8 +121,12 @@ impl From<ValueV1> for crate::values::Value {
115
121
crate :: db:: v1_types:: ValueV1 :: NestedResource ( sub_resource_v1) => {
116
122
Self :: NestedResource ( sub_resource_v1. into ( ) )
117
123
}
118
- crate :: db:: v1_types:: ValueV1 :: Resource ( _resource_v1) => {
119
- panic ! ( "ResourceV1 is not supported" )
124
+ crate :: db:: v1_types:: ValueV1 :: Resource ( resource_v1) => {
125
+ tracing:: warn!(
126
+ "Named SubResource found, converting to Subject {}" ,
127
+ resource_v1. subject
128
+ ) ;
129
+ return Self :: AtomicUrl ( resource_v1. subject ) ;
120
130
}
121
131
crate :: db:: v1_types:: ValueV1 :: Boolean ( v) => Self :: Boolean ( v) ,
122
132
crate :: db:: v1_types:: ValueV1 :: Unsupported ( unsupported_value) => {
You can’t perform that action at this time.
0 commit comments