BEAKING(buffer): remove Deno.readAll[Sync]() (#25386)

Towards #22079

Signed-off-by: Asher Gomez <ashersaupingomez@gmail.com>
This commit is contained in:
Asher Gomez 2024-09-04 18:54:50 +10:00 committed by GitHub
parent 3d36cbd056
commit 7e11dbb3ac
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 1 additions and 53 deletions

View file

@ -234,26 +234,4 @@ class Buffer {
}
}
async function readAll(r) {
internals.warnOnDeprecatedApi(
"Deno.readAll()",
new Error().stack,
"Use `readAll()` from `https://jsr.io/@std/io/doc/read-all/~` instead.",
);
const buf = new Buffer();
await buf.readFrom(r);
return buf.bytes();
}
function readAllSync(r) {
internals.warnOnDeprecatedApi(
"Deno.readAllSync()",
new Error().stack,
"Use `readAllSync()` from `https://jsr.io/@std/io/doc/read-all/~` instead.",
);
const buf = new Buffer();
buf.readFromSync(r);
return buf.bytes();
}
export { Buffer, readAll, readAllSync };
export { Buffer };