-
-
Notifications
You must be signed in to change notification settings - Fork 166
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
FIXES: fix lint issues Fixes: #1106
Closed
Closed
Changes from 4 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
4df5235
Migrate ESLint configuration to eslint.config.js, fix lint issues
Anshgrover23 d07dcee
Resolved linting and indentation errors
Anshgrover23 178eec0
fixed lint error specially optional chaining parsing errrors fixed.
Anshgrover23 e8621bc
fixed all linting issues specially solved optional chaining errors
Anshgrover23 aa02fc2
resolved requested errors
Anshgrover23 eb3e863
done with requested errors
Anshgrover23 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,36 @@ | ||
{ | ||
"extends": ["taller/react"], | ||
"extends": [ | ||
"taller/react", | ||
"eslint:recommended", | ||
"plugin:react/recommended" | ||
], | ||
"globals": { | ||
"DEV": false, | ||
"MOCK_GRAPHQL__": false, | ||
"drupalSettings": false, | ||
"xdescribe": false, | ||
"xit": false | ||
}, | ||
"parser": "babel-eslint", | ||
"parserOptions": { | ||
"ecmaVersion": 2020, | ||
"sourceType": "module", | ||
"ecmaFeatures": { | ||
"jsx": true | ||
} | ||
}, | ||
"settings": { | ||
"react": { | ||
"version": "detect" // Automatically detect the React version | ||
} | ||
}, | ||
"rules": { | ||
"no-mixed-operators": 0, | ||
"import/first": 0, | ||
"prefer-promise-reject-errors": 0, | ||
"react/prop-types": 0, | ||
"react/jsx-no-bind": 0 | ||
"react/jsx-no-bind": 0, | ||
"react/jsx-indent-props": ["error", 2] // Enforce 2-space indentation for JSX props | ||
// Add any additional rules specific to your project | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,17 +40,17 @@ const OrderCron = { | |
}, | ||
checkExpiredPaypalOrders: async () => { | ||
const orders = await models.Order.findAll({ where: { | ||
status: { | ||
[Op.eq]: 'succeeded' | ||
}, | ||
provider: { | ||
[Op.eq]: 'paypal' | ||
}, | ||
paid: { | ||
[Op.eq]: true | ||
} | ||
status: { | ||
[Op.eq]: 'succeeded' | ||
}, | ||
provider: { | ||
[Op.eq]: 'paypal' | ||
}, | ||
include: [ models.User, models.Task ] | ||
paid: { | ||
[Op.eq]: true | ||
} | ||
}, | ||
include: [ models.User, models.Task ] | ||
}) | ||
if (orders[0]) { | ||
try { | ||
|
@@ -81,27 +81,27 @@ const OrderCron = { | |
}).then(result => { | ||
return JSON.parse(result) | ||
}).catch(e => { | ||
console.log('error on order details', e.error) | ||
// console.log('error on order details', e.error) | ||
return JSON.parse(e.error) | ||
}) | ||
const orderDetailsResult = await orderDetails() | ||
if(orderDetailsResult["name"] === 'RESOURCE_NOT_FOUND') { | ||
const orderDetailsResult = await orderDetails() | ||
if (orderDetailsResult['name'] === 'RESOURCE_NOT_FOUND') { | ||
return models.Order.update({ status: 'expired', paid: false }, { where: { id: o.dataValues.id } }).then(orderUpdated => { | ||
if(orderUpdated[0] === 1) { | ||
if (orderUpdated[0] === 1) { | ||
orderMail.expiredOrders(order) | ||
return; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. you removed a return statement needed here |
||
} | ||
}) | ||
} | ||
} | ||
} | ||
}) | ||
} catch (e) { | ||
console.log('error', e) | ||
} | ||
catch (e) { | ||
// console.log('error', e) | ||
} | ||
} | ||
return orders | ||
} | ||
} | ||
|
||
module.exports = OrderCron | ||
module.exports = OrderCron |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -112,7 +112,7 @@ const fetchTransferSuccess = (data) => { | |
|
||
const fetchTransferFailed = (error) => { | ||
return { | ||
type: FETCH_TRANSFER, | ||
type: FETCH_TRANSFER_FAILED, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. great catch 💯 |
||
error: error, | ||
completed: true | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you're commenting here a line that can affect the tests besides the console, please don't do so.
You can remove the console and keep the line with the return