mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 06:49:14 +08:00
PERF: Pass element to resolveAllShortUrl function, not text selector (#9988)
We already have a reference to the preview element, so there is no need to look it up again. This saves about 1ms per keypress in my testing.
This commit is contained in:
parent
731263b81c
commit
be5974734d
|
@ -1000,7 +1000,7 @@ export default Component.extend({
|
|||
);
|
||||
|
||||
// Short upload urls need resolution
|
||||
resolveAllShortUrls(ajax, this.siteSettings, ".d-editor-preview-wrapper");
|
||||
resolveAllShortUrls(ajax, this.siteSettings, $preview[0]);
|
||||
|
||||
if (this._enableAdvancedEditorPreviewSync()) {
|
||||
this._syncScroll(
|
||||
|
|
Loading…
Reference in New Issue
Block a user