Skip to content

Commit

Permalink
fix: Improovment link preview to prioritize the native function
Browse files Browse the repository at this point in the history
  • Loading branch information
icleitoncosta committed May 9, 2024
1 parent 46a6c28 commit ffa4eaa
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/chat/functions/prepareLinkPreview.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,8 @@ webpack.onFullReady(() => {
wrapModuleFunction(getABPropConfigValue, (func, ...args) => {
const [key] = args;
switch (key) {
case 'high_quality_link_preview_enabled':
return true;
case 'link_preview_wait_time':
return 1;
return 7;
}
return func(...args);
});
Expand Down Expand Up @@ -150,7 +148,7 @@ webpack.onFullReady(() => {

resolve(result);
} catch (error) {
resolve(func(...args));
resolve(await func(...args));
}
});
});
Expand Down

0 comments on commit ffa4eaa

Please sign in to comment.