enhance Files_encode()