Skip to content

Commit

Permalink
Merge branch 'development' into shaka-migration
Browse files Browse the repository at this point in the history
  • Loading branch information
absidue committed Jul 10, 2024
2 parents aca8c8b + b2fe59d commit 4151fad
Show file tree
Hide file tree
Showing 8 changed files with 82 additions and 75 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
"vue-observe-visibility": "^1.0.0",
"vue-router": "^3.6.5",
"vuex": "^3.6.2",
"youtubei.js": "^10.0.0"
"youtubei.js": "^10.1.0"
},
"devDependencies": {
"@babel/core": "^7.24.7",
Expand Down Expand Up @@ -104,7 +104,7 @@
"html-webpack-plugin": "^5.6.0",
"js-yaml": "^4.1.0",
"json-minimizer-webpack-plugin": "^5.0.0",
"lefthook": "^1.6.18",
"lefthook": "^1.7.1",
"mini-css-extract-plugin": "^2.9.0",
"npm-run-all2": "^6.2.2",
"postcss": "^8.4.39",
Expand Down
7 changes: 7 additions & 0 deletions src/main/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -936,6 +936,13 @@ function runApp() {

try {
const contents = await asyncFs.readFile(filePath)

// Probably a corrupted/broken cache entry, pretend it's absent
// A valid entry should be a few KB large
if (contents.byteLength < 500) {
return undefined
}

return contents.buffer
} catch (e) {
console.error(e)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -323,8 +323,8 @@ export default defineComponent({
}).catch((err) => {
console.error(err)
const errorMessage = this.$t('Invidious API Error (Click to copy)')
showToast(`${errorMessage}: ${err.responseText}`, 10000, () => {
copyToClipboard(err.responseText)
showToast(`${errorMessage}: ${err}`, 10000, () => {
copyToClipboard(err)
})
switch (failedAttempts) {
case 0:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -324,8 +324,8 @@ export default defineComponent({
}).catch((err) => {
console.error(err)
const errorMessage = this.$t('Invidious API Error (Click to copy)')
showToast(`${errorMessage}: ${err.responseText}`, 10000, () => {
copyToClipboard(err.responseText)
showToast(`${errorMessage}: ${err}`, 10000, () => {
copyToClipboard(err)
})
switch (failedAttempts) {
case 0:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -366,11 +366,11 @@ export default defineComponent({
}

this.isLoading = false
}).catch((xhr) => {
console.error(xhr)
}).catch((error) => {
console.error(error)
const errorMessage = this.$t('Invidious API Error (Click to copy)')
showToast(`${errorMessage}: ${xhr.responseText}`, 10000, () => {
copyToClipboard(xhr.responseText)
showToast(`${errorMessage}: ${error}`, 10000, () => {
copyToClipboard(error)
})
this.isLoading = false
})
Expand Down
4 changes: 2 additions & 2 deletions src/renderer/views/Trending/Trending.js
Original file line number Diff line number Diff line change
Expand Up @@ -164,8 +164,8 @@ export default defineComponent({
}).catch((err) => {
console.error(err)
const errorMessage = this.$t('Invidious API Error (Click to copy)')
showToast(`${errorMessage}: ${err.responseText}`, 10000, () => {
copyToClipboard(err.responseText)
showToast(`${errorMessage}: ${err}`, 10000, () => {
copyToClipboard(err)
})

if (process.env.SUPPORTS_LOCAL_API && (this.backendPreference === 'invidious' && this.backendFallback)) {
Expand Down
4 changes: 2 additions & 2 deletions src/renderer/views/Watch/Watch.js
Original file line number Diff line number Diff line change
Expand Up @@ -919,8 +919,8 @@ export default defineComponent({
.catch(err => {
console.error(err)
const errorMessage = this.$t('Invidious API Error (Click to copy)')
showToast(`${errorMessage}: ${err.responseText}`, 10000, () => {
copyToClipboard(err.responseText)
showToast(`${errorMessage}: ${err}`, 10000, () => {
copyToClipboard(err)
})
console.error(err)
if (process.env.SUPPORTS_LOCAL_API && this.backendPreference === 'invidious' && this.backendFallback) {
Expand Down
122 changes: 61 additions & 61 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5327,10 +5327,10 @@ jest-worker@^29.7.0:
merge-stream "^2.0.0"
supports-color "^8.0.0"

jintr@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/jintr/-/jintr-1.1.0.tgz#223a3b07f5e03d410cec6e715c537c8ad1e714c3"
integrity sha512-Tu9wk3BpN2v+kb8yT6YBtue+/nbjeLFv4vvVC4PJ7oCidHKbifWhvORrAbQfxVIQZG+67am/mDagpiGSVtvrZg==
jintr@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/jintr/-/jintr-2.0.0.tgz#bc8e78efc04743f5c67c625587ce4d1c94afad9a"
integrity sha512-RiVlevxttZ4eHEYB2dXKXDXluzHfRuw0DJQGsYuKCc5IvZj5/GbOakeqVX+Bar/G9kTty9xDJREcxukurkmYLA==
dependencies:
acorn "^8.8.0"

Expand Down Expand Up @@ -5483,59 +5483,59 @@ lazy-val@^1.0.4, lazy-val@^1.0.5:
resolved "https://registry.yarnpkg.com/lazy-val/-/lazy-val-1.0.5.tgz#6cf3b9f5bc31cee7ee3e369c0832b7583dcd923d"
integrity sha512-0/BnGCCfyUMkBpeDgWihanIAF9JmZhHBgUhEqzvf+adhNGLoP6TaiI5oF8oyb3I45P+PcnrqihSf01M0l0G5+Q==

lefthook-darwin-arm64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-darwin-arm64/-/lefthook-darwin-arm64-1.6.18.tgz#9908a442b1cedd3f2d1f01dd4c021e97815e1605"
integrity sha512-AkpsTeO7aLZIIy6CKQ7Chx8RltE8a9uItbwQWoeaCkIdzpV8TFjq7/Pw4F5CkoJ2315sHtB8k+VFkgipQMBw1w==

lefthook-darwin-x64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-darwin-x64/-/lefthook-darwin-x64-1.6.18.tgz#e26ed583764f80652f242e48a824c7fbefa3bbb5"
integrity sha512-qwKa+PaNIYjZ2PVrRRLq+HjNjQsjEItXN21byvSD89r7EYCULsIC8aW4H6aniOP2A6X1DIZ+djpg+3hNJ/94NA==

lefthook-freebsd-arm64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-freebsd-arm64/-/lefthook-freebsd-arm64-1.6.18.tgz#e4b5c86d178572cd562c52b0ce1f5af247de8383"
integrity sha512-UIOzQ+okwB7Ah9p8sNqomOiU6cPfmJnyW3HDPutRsdoHRD8udIap9d+ja4Kg4m/PkoYtkcLO78omANqAgA5wxQ==

lefthook-freebsd-x64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-freebsd-x64/-/lefthook-freebsd-x64-1.6.18.tgz#45bf1c30aabc6ef9b7e0d576798f5606d8a48b3c"
integrity sha512-UQANUgyNpaAh0+2/PjPFiJ7yd6aF15yyJxKZCXyna5cQF7VU8pSHu5tiDDquNpjToXOg+6TmiIAJKyfrrwTF3w==

lefthook-linux-arm64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-linux-arm64/-/lefthook-linux-arm64-1.6.18.tgz#50d03e8e11217aec005464ba4da16f6b76be6e6c"
integrity sha512-4erletIa2HKUgY17/1ROvndAj6xn/9wkqO2GhBT3C0vFwIv6ycy5wpFzXOwKRZpFYv7UacN7iXhAZSK+vSOZZg==

lefthook-linux-x64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-linux-x64/-/lefthook-linux-x64-1.6.18.tgz#b630496aebcc360b570f8807a50099350dc00eeb"
integrity sha512-l5SRqYMYygw9RjZncEg8uh29wShYN8kiYr53sp74DkntrlCttqWhLILBUlIr3fxH5s0ZyrmqUEjtMBryMk7b/g==

lefthook-windows-arm64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-windows-arm64/-/lefthook-windows-arm64-1.6.18.tgz#f18afb1f173c41d666d1780102d0a122a685553f"
integrity sha512-jeNBRoya3+mOEsKyT4wXf29Kng1nkJD7Uv/dqGBszoGMktGVNUFdIjWoxx6HSfhUssucs5pKRZpXSMgK/KCP+Q==

lefthook-windows-x64@1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook-windows-x64/-/lefthook-windows-x64-1.6.18.tgz#9051e6d3f78ef0208521e31b200ad03c45f4d07d"
integrity sha512-iEG8PbFOwMqlpAgCiqzANTxutERjwlwMx6WF6HDGEYwFJSCJsvi06TehDxaPIFbhmLLYYlbVrfSBlttWGoN0dg==

lefthook@^1.6.18:
version "1.6.18"
resolved "https://registry.yarnpkg.com/lefthook/-/lefthook-1.6.18.tgz#ba15055f5a57c77ecda2c1e0cbdfde3c3fe317f5"
integrity sha512-Ftr/NkU1P1EsEyphsCqCX7lesGZA+QDXyUx4dS1RlSKB72xKtGW9VPjbGLK2kSQkONG5M+XYfbJkGA/r9NLTYQ==
lefthook-darwin-arm64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-darwin-arm64/-/lefthook-darwin-arm64-1.7.1.tgz#d6cbbfe6988a995ea32e4c92d6f99d54c2bbd440"
integrity sha512-WNM92Ix2rKmDKXzjlkVGCdzSkzzj3Z9D7yKi22KeOZ1iCXG1EtXEWmXO5M2g28FNb4cZI0r2DACNH5hz8JsfgA==

lefthook-darwin-x64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-darwin-x64/-/lefthook-darwin-x64-1.7.1.tgz#b2683a73da0a1ea86c6bc16be188743a955f12a7"
integrity sha512-SDPEciuP+eNzuKN8kx1x0dRzFElpO65on5q0raKgTbTvSOyVd3c7sMLGluz6OSM5qqEWEdEeA8QYKpdA56uXEw==

lefthook-freebsd-arm64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-freebsd-arm64/-/lefthook-freebsd-arm64-1.7.1.tgz#0cc51b81236bc0465fd8c1842a7cf63840d24d90"
integrity sha512-Ym2hhv6w7RWva3jfjtBOYck+GiaCx1JpnsOCf9tDYKFiV6ve/DoLrGQ+uI0UOqtiHN/bJzt5BrNXygfAubXaEg==

lefthook-freebsd-x64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-freebsd-x64/-/lefthook-freebsd-x64-1.7.1.tgz#47b2584a578dc9a28d185c94e3bd620b30a79c70"
integrity sha512-u9WYd+LDJr1A+VQV6lTe1a0yG0Ew9Wgeb9Ym9IKr9eLblrt6JNvW1x9u0e9OFteLwnqBCCT8omBY+NARcvqVvg==

lefthook-linux-arm64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-linux-arm64/-/lefthook-linux-arm64-1.7.1.tgz#4ce35be13553a78c0800ddc5771fb29848e39dee"
integrity sha512-Sgc+vHNnAbiJ5b1yMJsFn/rQ6eVQ0KLzuL0x0KJqFZvmffFenVmqABrFHKNDzhj8//KUbHdgCgLzqQAkAbCNcg==

lefthook-linux-x64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-linux-x64/-/lefthook-linux-x64-1.7.1.tgz#b757ff298724083c1fa06cee5fa05480e1f96e24"
integrity sha512-UDIM6Cf0aHrfvIxeVz05M7g+omLdyTQpmB2BqkeANpd/5+1LqRMOBOdtW+y3X47NKYL++iFh2EtIhlIqVBj6Kw==

lefthook-windows-arm64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-windows-arm64/-/lefthook-windows-arm64-1.7.1.tgz#45c5f9b2b0ab2d7260602037b98e156eacb43d1f"
integrity sha512-cz3vhIdmORA25YF4ZnPjDQwi/KQd8cB89q7jHEQ9sv+bpSOTXiauMOM9jvXbnvGrmFaR1qbLRTYpKQs6oyGdsA==

lefthook-windows-x64@1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook-windows-x64/-/lefthook-windows-x64-1.7.1.tgz#9575fe23af4f6d7ef0c958431f20dd6ca5fe7162"
integrity sha512-Fa9HEkJczbD1zu6wBKP2rR738uRei5sb76d/DzgqW09ZBTwQl+6Oiyg3kicVU1N1X8bhZ/g1h49tcHrVtjU5ww==

lefthook@^1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/lefthook/-/lefthook-1.7.1.tgz#c31f57dd42a28fed22376db519fb40c4c3064398"
integrity sha512-WNgjrPH4bYZyAYsiK7y7roQCQFIgqdCFxVCVe7ylAFD+QvW8tMceG19mR3GS2if1fGHC/cs+Z0r6PI52b/G1eA==
optionalDependencies:
lefthook-darwin-arm64 "1.6.18"
lefthook-darwin-x64 "1.6.18"
lefthook-freebsd-arm64 "1.6.18"
lefthook-freebsd-x64 "1.6.18"
lefthook-linux-arm64 "1.6.18"
lefthook-linux-x64 "1.6.18"
lefthook-windows-arm64 "1.6.18"
lefthook-windows-x64 "1.6.18"
lefthook-darwin-arm64 "1.7.1"
lefthook-darwin-x64 "1.7.1"
lefthook-freebsd-arm64 "1.7.1"
lefthook-freebsd-x64 "1.7.1"
lefthook-linux-arm64 "1.7.1"
lefthook-linux-x64 "1.7.1"
lefthook-windows-arm64 "1.7.1"
lefthook-windows-x64 "1.7.1"

levn@^0.4.1:
version "0.4.1"
Expand Down Expand Up @@ -8589,11 +8589,11 @@ yocto-queue@^1.0.0:
resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-1.0.0.tgz#7f816433fb2cbc511ec8bf7d263c3b58a1a3c251"
integrity sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g==

youtubei.js@^10.0.0:
version "10.0.0"
resolved "https://registry.yarnpkg.com/youtubei.js/-/youtubei.js-10.0.0.tgz#73ef7421302569c6cd6a163c12df393f13da480f"
integrity sha512-4Mmguxyw1TK1Co+gbx+41SFR55DR3OzMCdFW8OrSENjAjjOY9RDg7sKFbR+ZLsT3ga9AH1/nq+14KUItT9pPHQ==
youtubei.js@^10.1.0:
version "10.1.0"
resolved "https://registry.yarnpkg.com/youtubei.js/-/youtubei.js-10.1.0.tgz#38b3d95907441040df1e8031e04e0e6200ed52cf"
integrity sha512-MokZMAnpWH11VYvWuW6qjPiiPmgRl5rfDgPQOpif9qXcVHoVw1hi8ePuRSD0AZSZ+uvWGe8rvas2dzp+Jv5JKQ==
dependencies:
jintr "^1.1.0"
jintr "^2.0.0"
tslib "^2.5.0"
undici "^5.19.1"

0 comments on commit 4151fad

Please sign in to comment.