Skip to content

Commit

Permalink
Update dependency axios to v1 [SECURITY] (#3343)
Browse files Browse the repository at this point in the history
* Update dependency axios to v1 [SECURITY]

* Fix jest build for axios

* Fix axios import for vue-server-renderer

https://github.com/axios/axios/issues/5243\#issuecomment-1533941896

* Fix axios mock adapter import

---------

Co-authored-by: sarayourfriend <24264157+sarayourfriend@users.noreply.github.com>
openverse-bot and sarayourfriend authored Nov 15, 2023

Partially verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
We cannot verify signatures from co-authors, and some of the co-authors attributed to this commit require their commits to be signed.
1 parent be5c94d commit 671f0f2
Showing 5 changed files with 28 additions and 32 deletions.
2 changes: 1 addition & 1 deletion automations/js/package.json
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@
"version": "0.0.0",
"dependencies": {
"@octokit/rest": "19.0.7",
"axios": "^0.27.0",
"axios": "^1.0.0",
"js-yaml": "^4.1.0",
"k6": "0.0.0",
"nunjucks": "^3.2.4"
3 changes: 2 additions & 1 deletion frontend/jest.config.js
Original file line number Diff line number Diff line change
@@ -12,6 +12,7 @@ module.exports = {
"^~~/(.*)$": "<rootDir>/$1",
"^vue$": "vue/dist/vue.common.js",
"(.*svg)(\\?inline)$": "<rootDir>/test/unit/test-utils/svgTransform.js",
"^axios$": "axios/dist/node/axios.cjs",
},
setupFiles: ["<rootDir>/test/unit/setup.js"],
setupFilesAfterEnv: ["<rootDir>/test/unit/setup-after-env.js"],
@@ -22,7 +23,7 @@ module.exports = {
"^.+\\.svg$": "<rootDir>/test/unit/svg-transform.js",
},
testPathIgnorePatterns: ["/playwright/", "/storybook/", ".remake"],
collectCoverage: true,
collectCoverage: false,
coverageDirectory: "<rootDir>/test/unit/coverage",
collectCoverageFrom: [
"<rootDir>/src/**/*.vue",
1 change: 1 addition & 0 deletions frontend/nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -261,6 +261,7 @@ const config: NuxtConfig = {
// Enables use of IDE debuggers
config.devtool = ctx.isClient ? "source-map" : "inline-source-map"
},
transpile: [({ isLegacy }) => (isLegacy ? "axios" : undefined)],
},
typescript: {
typeCheck: {
2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
@@ -70,7 +70,7 @@
"@vueuse/core": "^10.2.1",
"@wordpress/is-shallow-equal": "^4.6.0",
"async-mutex": "^0.3.2",
"axios": "^0.27.0",
"axios": "^1.0.0",
"axios-mock-adapter": "^1.20.0",
"clipboard": "^2.0.11",
"cookie-universal-nuxt": "^2.1.5",
52 changes: 23 additions & 29 deletions pnpm-lock.yaml

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

0 comments on commit 671f0f2

Please sign in to comment.