File tree 3 files changed +7
-6
lines changed
3 files changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ def relative?
89
89
end
90
90
91
91
def relative_path_from ( other )
92
- FasterPath . relative_path_from ( @path , Pathname ( other ) )
92
+ FasterPath . relative_path_from ( @path , other )
93
93
end
94
94
end
95
95
end
Original file line number Diff line number Diff line change @@ -84,7 +84,7 @@ def relative?
84
84
end
85
85
86
86
def relative_path_from ( other )
87
- FasterPath . relative_path_from ( @path , Pathname ( other ) )
87
+ FasterPath . relative_path_from ( @path , other )
88
88
end
89
89
end
90
90
end
Original file line number Diff line number Diff line change @@ -146,10 +146,11 @@ methods!(
146
146
147
147
// fn r_split_names(pth: RString){}
148
148
149
- fn pub_relative_path_from( itself: RString , base_directory: RString ) -> Pathname {
150
- pathname:: pn_relative_path_from( itself, base_directory) . map_err( |e| {
151
- raise( e) ;
152
- } ) . unwrap( )
149
+ fn pub_relative_path_from( itself: RString , base_directory: AnyObject ) -> Pathname {
150
+ let to_string = |i: AnyObject | { RString :: from( i. send( "to_s" , None ) . value( ) ) } ;
151
+
152
+ pathname:: pn_relative_path_from( itself, base_directory. map( to_string) ) .
153
+ map_err( |e| raise( e) ) . unwrap( )
153
154
}
154
155
155
156
// fn pub_rmtree(pth: RString) -> NilClass {
You can’t perform that action at this time.
0 commit comments