mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-28 01:21:47 +03:00
Use into_any instead of weird 'as' hack
This commit is contained in:
parent
27258a0889
commit
71cf6ec5ae
@ -457,10 +457,10 @@ impl Client {
|
||||
cx: &mut ViewContext<T>,
|
||||
) -> Subscription {
|
||||
let id = (TypeId::of::<T>(), remote_id);
|
||||
self.state.write().entities_by_type_and_remote_id.insert(
|
||||
id,
|
||||
WeakSubscriber::View((&cx.weak_handle() as &AnyWeakViewHandle).clone()),
|
||||
);
|
||||
self.state
|
||||
.write()
|
||||
.entities_by_type_and_remote_id
|
||||
.insert(id, WeakSubscriber::View(cx.weak_handle().into_any()));
|
||||
Subscription::Entity {
|
||||
client: Arc::downgrade(self),
|
||||
id,
|
||||
|
Loading…
Reference in New Issue
Block a user