-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
docs : fix variable assignment and importing PostRepository #4286
docs : fix variable assignment and importing PostRepository #4286
Conversation
|
@Shiva953 is attempting to deploy a commit to the medusajs Team on Vercel. A member of the Team first needs to authorize it. |
|
||
class PostService extends TransactionBaseService { | ||
protected readonly postRepository: typeof PostRepository; |
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.
suggestion: We generally suffix with _
to give the flexibility to have a getter and avoid any name conflict.
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.
sure
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.
@Shiva953 can you follow this guide to fix the ESLint errors?
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.
LGTM! Thanks for your contribution @Shiva953 !
* fix variable assignment and import in step-5 * update with postRepository_ suffix for flexibility and avoiding name conflicts * fixed ESLint Errors
Closes #3958
To resolve this issue, I have made the following changes:
Imported the
PostRepository
module, which was missing in the previous step.Declared the
postRepository
variable as a protected readonly property of typetypeof PostRepository
in the service class.Please review these changes and provide your feedback. If there are any further changes or improvements needed, please let me know and I'll be happy to make the necessary adjustments.
Thank you!