From b3e66ec1c3f21b672cc26ddd540e1343f3b57cda Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Fri, 13 Sep 2024 18:57:49 +0200 Subject: [PATCH] read/text --- rwx/fs/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rwx/fs/__init__.py b/rwx/fs/__init__.py index b1da3a2..82b7c16 100644 --- a/rwx/fs/__init__.py +++ b/rwx/fs/__init__.py @@ -62,7 +62,8 @@ def read_file_lines(file_path: str, charset: str = CHARSET): return read_file_text(file_path).split(os.linesep) -def read_file_text(file_path: str, charset: str = CHARSET): +def read_file_text(file_path: str, charset: str = CHARSET) -> str: + """Read whole file text.""" return read_file_bytes(file_path).decode(charset)