ADT-211 + DEVELOP-1305-2: Refactor github extension and empty state#31
ADT-211 + DEVELOP-1305-2: Refactor github extension and empty state#31
Conversation
| [IDENTIFIER, trigger].join("."), | ||
| true | ||
| ); | ||
| if ( |
There was a problem hiding this comment.
typescript doesn't yet support discrimination using includes
|
|
||
| // Generate events. | ||
| if (record) { | ||
| if (pr.head?.name) { |
There was a problem hiding this comment.
this is already done in getOrLinkPullRequestRecord
percyhanna
left a comment
There was a problem hiding this comment.
The aha-develop.github-v1.6.0.gz file should not be committed.
@percyhanna removed and .gitignore updated |
trydionel
left a comment
There was a problem hiding this comment.
Looks good from PM perspective!
Asking for review from the rest of the team while percy is away
| return await RecordClass.select(["id", "referenceNum"]).find( | ||
| ahaReference.referenceNum | ||
| ); |
There was a problem hiding this comment.
Can we use findBy() here to avoid throwing the UI alert if the record doesn't exist? (Returns the record or undefined if not found)
| return await RecordClass.select(["id", "referenceNum"]).find( | |
| ahaReference.referenceNum | |
| ); | |
| return await RecordClass.select(["id", "referenceNum"]).findBy({ | |
| id: ahaReference.referenceNum | |
| }); |
There was a problem hiding this comment.
I don't want to make this functional change right now
| }; | ||
|
|
||
| const pasteLink = async (url: string) => { | ||
| if (!validPrUrl(url)) { |
There was a problem hiding this comment.
Same as on the GitLab extension - new URL() throws if I put a junk string in, so the user doesn't get any validation feedback. try/catch?
This PR adds the new empty state to the GitHub extension and makes the following adjustments: