Web Search: recent search queries

Various Fixes
This commit is contained in:
Ilya Laktyushin
2018-12-11 23:38:59 +04:00
parent 241de58edd
commit d20523252f
141 changed files with 4365 additions and 1892 deletions

View File

@@ -1231,7 +1231,7 @@ public func groupInfoController(account: Account, peerId: PeerId) -> ViewControl
account.postbox.mediaBox.storeResourceData(resource.id, data: data)
let representation = TelegramMediaImageRepresentation(dimensions: CGSize(width: 640.0, height: 640.0), resource: resource)
updateState {
$0.withUpdatedUpdatingAvatar(.image(representation))
$0.withUpdatedUpdatingAvatar(.image(representation, true))
}
updateAvatarDisposable.set((updatePeerPhoto(postbox: account.postbox, network: account.network, stateManager: account.stateManager, accountPeerId: account.peerId, peerId: peerId, photo: uploadedPeerPhoto(postbox: account.postbox, network: account.network, resource: resource)) |> deliverOnMainQueue).start(next: { result in
switch result {
@@ -1250,7 +1250,7 @@ public func groupInfoController(account: Account, peerId: PeerId) -> ViewControl
let _ = currentAvatarMixin.swap(nil)
updateState {
if let profileImage = peer?.smallProfileImage {
return $0.withUpdatedUpdatingAvatar(.image(profileImage))
return $0.withUpdatedUpdatingAvatar(.image(profileImage, false))
} else {
return $0.withUpdatedUpdatingAvatar(.none)
}