Skip to content

API key NA guard not applied to embedding provider check #282

@seanthimons

Description

@seanthimons

Source: PR #278 review (round 1)
Severity: LOW
File: R/mod_search_notebook.R:2875

The embedding guard still uses nchar(provider_or$api_key) == 0 without an is.na() guard. nchar(NA) returns NA which causes a warning. The same is.na() || !nzchar() fix from mod_query_builder.R:82 should be applied here for consistency.

Suggested fix: Change to is.null(provider_or$api_key) || is.na(provider_or$api_key) || !nzchar(provider_or$api_key).

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions