fix: correct idaa_trig usage in recovery_meetings Zoom URL editor
$idaa_trig is a key_val object (dict of boolean flags), not a string signal. Adds update_zoom_full_url key to the store template and converts all 7 string comparisons/assignments to property access on the object. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -182,7 +182,8 @@ const idaa_trig_template: key_val = {
|
|||||||
archive_id: false,
|
archive_id: false,
|
||||||
archive_content_li: false,
|
archive_content_li: false,
|
||||||
event_id: false,
|
event_id: false,
|
||||||
post_id: false
|
post_id: false,
|
||||||
|
update_zoom_full_url: false
|
||||||
};
|
};
|
||||||
export const idaa_trig: Writable<key_val> = writable(idaa_trig_template);
|
export const idaa_trig: Writable<key_val> = writable(idaa_trig_template);
|
||||||
|
|
||||||
|
|||||||
@@ -689,13 +689,13 @@ if (browser && $idaa_slct.event_obj?.attend_json) {
|
|||||||
// attend_json.zoom.passcode_enc below throws a TypeError and crashes the component.
|
// attend_json.zoom.passcode_enc below throws a TypeError and crashes the component.
|
||||||
$effect(() => {
|
$effect(() => {
|
||||||
if (
|
if (
|
||||||
$idaa_trig == 'update_zoom_full_url' &&
|
$idaa_trig.update_zoom_full_url &&
|
||||||
$idaa_slct.event_obj.attend_url_code &&
|
$idaa_slct.event_obj.attend_url_code &&
|
||||||
$idaa_slct.event_obj.attend_url_passcode &&
|
$idaa_slct.event_obj.attend_url_passcode &&
|
||||||
$idaa_sess.recovery_meetings.attend_platform === 'Zoom' &&
|
$idaa_sess.recovery_meetings.attend_platform === 'Zoom' &&
|
||||||
$idaa_slct.event_obj.attend_json?.zoom // guard: zoom may be undefined after IDB re-fire
|
$idaa_slct.event_obj.attend_json?.zoom // guard: zoom may be undefined after IDB re-fire
|
||||||
) {
|
) {
|
||||||
$idaa_trig = null;
|
$idaa_trig.update_zoom_full_url = false;
|
||||||
|
|
||||||
$idaa_slct.event_obj.attend_url_code =
|
$idaa_slct.event_obj.attend_url_code =
|
||||||
String($idaa_slct.event_obj.attend_url_code)
|
String($idaa_slct.event_obj.attend_url_code)
|
||||||
@@ -1203,7 +1203,7 @@ $effect(() => {
|
|||||||
}
|
}
|
||||||
$idaa_sess.recovery_meetings.attend_platform =
|
$idaa_sess.recovery_meetings.attend_platform =
|
||||||
'Zoom';
|
'Zoom';
|
||||||
$idaa_trig = 'update_zoom_full_url';
|
$idaa_trig.update_zoom_full_url = true;
|
||||||
}}>
|
}}>
|
||||||
<span class="fas fa-video"></span> Zoom
|
<span class="fas fa-video"></span> Zoom
|
||||||
</button>
|
</button>
|
||||||
@@ -1319,7 +1319,7 @@ $effect(() => {
|
|||||||
''
|
''
|
||||||
).length > 8
|
).length > 8
|
||||||
) {
|
) {
|
||||||
$idaa_trig = 'update_zoom_full_url';
|
$idaa_trig.update_zoom_full_url = true;
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
class="input preset-tonal-surface hover:preset-filled-surface-100-900 w-52" />
|
class="input preset-tonal-surface hover:preset-filled-surface-100-900 w-52" />
|
||||||
@@ -1342,7 +1342,7 @@ $effect(() => {
|
|||||||
$idaa_slct.event_obj.attend_url_passcode
|
$idaa_slct.event_obj.attend_url_passcode
|
||||||
?.length > 3
|
?.length > 3
|
||||||
) {
|
) {
|
||||||
$idaa_trig = 'update_zoom_full_url';
|
$idaa_trig.update_zoom_full_url = true;
|
||||||
} else {
|
} else {
|
||||||
$idaa_slct.event_obj.attend_url_passcode =
|
$idaa_slct.event_obj.attend_url_passcode =
|
||||||
'';
|
'';
|
||||||
@@ -1388,7 +1388,7 @@ $effect(() => {
|
|||||||
$idaa_slct.event_obj.attend_json.zoom
|
$idaa_slct.event_obj.attend_json.zoom
|
||||||
.passcode_enc?.length >= 8
|
.passcode_enc?.length >= 8
|
||||||
) {
|
) {
|
||||||
$idaa_trig = 'update_zoom_full_url';
|
$idaa_trig.update_zoom_full_url = true;
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
class="input preset-tonal-surface hover:preset-filled-surface-100-900 w-72" />
|
class="input preset-tonal-surface hover:preset-filled-surface-100-900 w-72" />
|
||||||
@@ -1421,7 +1421,7 @@ $effect(() => {
|
|||||||
.toLowerCase()
|
.toLowerCase()
|
||||||
.trim()
|
.trim()
|
||||||
: 'zoom.us';
|
: 'zoom.us';
|
||||||
$idaa_trig = 'update_zoom_full_url';
|
$idaa_trig.update_zoom_full_url = true;
|
||||||
}}
|
}}
|
||||||
class="input preset-tonal-surface hover:preset-filled-surface-100-900 w-56" />
|
class="input preset-tonal-surface hover:preset-filled-surface-100-900 w-56" />
|
||||||
</label>
|
</label>
|
||||||
|
|||||||
Reference in New Issue
Block a user