diff options
| author | Craig Jennings <c@cjennings.net> | 2026-05-25 07:44:32 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2026-05-25 07:44:32 -0500 |
| commit | 808ca1183c5288183fd3be2607887e21ae6e9c68 (patch) | |
| tree | dbc553907074e9381dc93ed4d86aebf696e6f2c1 | |
| parent | 8ad9fce0f469cecd4d4b682c25272348f35259b2 (diff) | |
| download | pearl-808ca1183c5288183fd3be2607887e21ae6e9c68.tar.gz pearl-808ca1183c5288183fd3be2607887e21ae6e9c68.zip | |
refactor: drop the now-dead issue-id guards in the field setters
pearl-set-state, pearl-set-assignee, and pearl-set-labels each kept an (unless issue-id (user-error ...)) check that became unreachable once they switched to pearl--goto-issue-heading-or-error, which already signals when no enclosing issue heading carries LINEAR-ID. I removed the three dead guards; the climbing guard is the single source of that error now.
| -rw-r--r-- | pearl.el | 6 |
1 files changed, 0 insertions, 6 deletions
@@ -2730,8 +2730,6 @@ success. Works from anywhere inside an issue subtree." (state (seq-find (lambda (s) (string= (cdr (assoc 'name s)) state-name)) states)) (state-id (and state (cdr (assoc 'id state))))) - (unless issue-id - (user-error "Not on a Linear issue heading")) (unless state-id (user-error "No workflow state named %s in this team" state-name)) (pearl--push-issue-field @@ -2765,8 +2763,6 @@ anywhere inside an issue subtree." (marker (point-marker)) (assignee-id (and team-id (pearl--resolve-team-id 'members assignee-name team-id)))) - (unless issue-id - (user-error "Not on a Linear issue heading")) (unless assignee-id (user-error "No team member matching %s" assignee-name)) (pearl--push-issue-field @@ -2802,8 +2798,6 @@ issue subtree." (pearl--resolve-team-id 'labels name team-id)) (user-error "No label matching %s" name))) label-names))) - (unless issue-id - (user-error "Not on a Linear issue heading")) (pearl--push-issue-field issue-id marker `(("labelIds" . ,label-ids)) (lambda () |
