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

Release v4.0.2 #325

Merged
merged 1 commit into from
Sep 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Jira.js changelog

### 4.0.2

- `getAllProjects` in README and examples replaced to `searchProjects`. Thanks to [Alexander Pivovarov](https://github.com/bladerunner2020) for reporting [the issue](https://github.com/MrRefactoring/jira.js/issues/323).
- Personal access token link changed to actual in README
- Test platform changed from `ava` to `vitest`
- Dependencies updated
- Vulnerabilities fixes

### 4.0.1

- Vulnerabilities fixes
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,9 @@ const client = new Version3Client({
});
```

##### [Personal access token](https://confluence.atlassian.com/enterprise/using-personal-access-tokens-1026032365.html)
##### [Personal access token](https://id.atlassian.com/manage-profile/security/api-tokens)

To create a personal access token, use this link: [https://id.atlassian.com/manage-profile/security/api-tokens](https://id.atlassian.com/manage-profile/security/api-tokens)

```typescript
import { Version3Client } from 'jira.js';
Expand Down Expand Up @@ -175,7 +177,7 @@ const client = new Version3Client({
});

async function main() {
const projects = await client.projects.getAllProjects();
const { values: projects } = await client.projects.searchProjects();

if (projects.length) {
const project = projects[0];
Expand Down
20 changes: 10 additions & 10 deletions examples/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion examples/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
},
"license": "MIT",
"devDependencies": {
"@types/node": "^22.5.2",
"@types/node": "^22.5.4",
"ts-node": "^10.9.2",
"typescript": "^5.5.4"
},
Expand Down
2 changes: 1 addition & 1 deletion examples/src/basic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
});

async function main() {
const projects = await client.projects.getAllProjects();
const { values: projects } = await client.projects.searchProjects();

if (projects.length) {
const project = projects[0];
Expand All @@ -28,7 +28,7 @@

const issue = await client.issues.getIssue({ issueIdOrKey: id });

console.log(`Issue '${issue.fields.summary}' was successfully added to '${project.name}' project.`);

Check warning on line 31 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (18.x)

Unexpected console statement

Check warning on line 31 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (20.x)

Unexpected console statement

Check warning on line 31 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (18.x)

Unexpected console statement

Check warning on line 31 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (20.x)

Unexpected console statement
} else {
const myself = await client.myself.getCurrentUser();

Expand All @@ -41,13 +41,13 @@

const project = await client.projects.getProject({ projectIdOrKey: id.toString() });

console.log(`Project '${project.name}' was successfully created.`);

Check warning on line 44 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (18.x)

Unexpected console statement

Check warning on line 44 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (20.x)

Unexpected console statement

Check warning on line 44 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (18.x)

Unexpected console statement

Check warning on line 44 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (20.x)

Unexpected console statement
}
}

main()
.catch(e => {
console.error(e);

Check warning on line 50 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (18.x)

Unexpected console statement

Check warning on line 50 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (20.x)

Unexpected console statement

Check warning on line 50 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (18.x)

Unexpected console statement

Check warning on line 50 in examples/src/basic.ts

View workflow job for this annotation

GitHub Actions / Lint Code (20.x)

Unexpected console statement

throw new Error(JSON.stringify(e));
});
2 changes: 1 addition & 1 deletion examples/src/utils/createIssue.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Version3Client } from 'jira.js';

export const createIssue = async (client: Version3Client) => {
const projects = await client.projects.getAllProjects();
const { values: projects } = await client.projects.searchProjects();

if (projects.length) {
const { key } = projects[0];
Expand Down
Loading
Loading