Commit cb47e1c0 authored by Quoc Huy Nguyen Dinh's avatar Quoc Huy Nguyen Dinh

Sharp's crop() is deprecated

parent ff34821e
......@@ -319,7 +319,7 @@ export async function proxyHandler(ctx: KoaContext) {
switch (options.mode) {
case ScalingMode.Cover:
image.rotate().resize(width, height).crop()
image.rotate().resize(width, height, {fit: 'cover'})
case ScalingMode.Fit:
if (!width) { width = maxWidth }
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment