Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't timeout if the completion variable is already set #287

Merged
merged 3 commits into from
Mar 25, 2021

Conversation

Congelli501
Copy link
Contributor

No description provided.

@codecov
Copy link

codecov bot commented Nov 15, 2020

Codecov Report

Merging #287 (724d233) into master (3e281d6) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##            master      #287   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            9         9           
  Lines          145       145           
  Branches        20        20           
=========================================
  Hits           145       145           
Impacted Files Coverage Δ
src/CompletionTriggers/Variable.ts 100.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3e281d6...724d233. Read the comment docs.

Copy link
Owner

@westy92 westy92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution! 🎉

Please add a unit test to verify this new behavior and answer my question.

@@ -29,10 +29,15 @@ export class Variable extends CompletionTrigger {
awaitPromise: true,
expression: `
new Promise((resolve, reject) => {
Object.defineProperty(window, '${varName}', {
if (window[${JSON.stringify(varName)}] === true) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What advantages are there to using ${JSON.stringify(varName)} over ${varName}?

@westy92
Copy link
Owner

westy92 commented Dec 15, 2020

@Congelli501 have you had a chance to review my comments?

@westy92
Copy link
Owner

westy92 commented Mar 25, 2021

I made my desired changes. Thank you for your contribution! 🎉

@westy92 westy92 merged commit db38386 into westy92:master Mar 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants