Skip to content

Commit

Permalink
v1.7.0 (#105)
Browse files Browse the repository at this point in the history
* ci: add build check to pull requests

* Build(deps-dev): Bump @types/node from 20.10.6 to 20.11.24 (#91)

Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 20.10.6 to 20.11.24.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* feat: image compression (#101)

* feat: image compression

* fix: not compress svg

Maybe we should add a function to disable this fix. Since I noticed that if you compress svg in webp it becomes magically smaller.

* Configuration page (#104)

* feat: image compression

* feat: configuration page

* refactor: json stringify

and change engine buttons to ordered list

* fix: engine distributor matching

* fix: formatting

* build: update txtdot version to 1.7.0

* fix: configuration page title

* doc: features (#102)

* fix: delete islocal from proxy

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
  • Loading branch information
artegoser and dependabot[bot] authored Mar 7, 2024
1 parent 7c72d98 commit 2fd7ec5
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/routes/browser/proxy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,11 @@ import sharp from 'sharp';
import getConfig from '../../config/main';
import { UnsupportedMimetypeError } from '../../errors/main';

import isLocalResource from '../../utils/islocal';
import { LocalResourceError } from '../../errors/main';

export default async function proxyRoute(fastify: FastifyInstance) {
fastify.get<IProxySchema>(
'/proxy',
{ schema: ProxySchema },
async (request, reply) => {
if (await isLocalResource(new URL(request.query.url))) {
throw new LocalResourceError();
}

const response = await axios.get(request.query.url);
const mime: string | undefined =
response.headers['content-type']?.toString();
Expand Down

0 comments on commit 2fd7ec5

Please sign in to comment.