mirror of
https://github.com/lllin000/PaperForge.git
synced 2026-07-22 06:50:53 +00:00
fix(plugin): undeclared customText variable in _renderHfMirror
This commit is contained in:
parent
0ea0b02f3a
commit
e70d98506c
1 changed files with 2 additions and 2 deletions
|
|
@ -2975,7 +2975,7 @@ class PaperForgeSettingTab extends PluginSettingTab {
|
|||
if (value !== '__custom__') {
|
||||
this.plugin.settings.vector_db_hf_endpoint = value;
|
||||
this.plugin.saveSettings();
|
||||
if (customInput) { customInput.settingEl.style.display = 'none'; if (customText) customText.setValue(''); }
|
||||
if (customInput) { customInput.settingEl.style.display = 'none'; if (this._hfCustomText) this._hfCustomText.setValue(''); }
|
||||
} else {
|
||||
if (customInput) customInput.settingEl.style.display = '';
|
||||
}
|
||||
|
|
@ -2985,7 +2985,7 @@ class PaperForgeSettingTab extends PluginSettingTab {
|
|||
.setName(t('feat_custom_endpoint'))
|
||||
.setDesc(t('feat_custom_endpoint_desc'))
|
||||
.addText(text => {
|
||||
customText = text;
|
||||
this._hfCustomText = text;
|
||||
const current = this.plugin.settings.vector_db_hf_endpoint || '';
|
||||
const isPreset = ['https://hf-mirror.com', 'https://huggingface.co'].includes(current);
|
||||
text.setPlaceholder('https://your-mirror.com')
|
||||
|
|
|
|||
Loading…
Reference in a new issue