Skip to content

Commit

Permalink
[FIX] hw_drivers: In IoT adapt path to filename
Browse files Browse the repository at this point in the history
From the commit 2ab231b
We introduce a error in the path to read Linux file

In this commit we correct the access to the file
which is in the "home" of the raspberry

closes odoo#107762

Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
  • Loading branch information
qle-odoo committed Dec 12, 2022
1 parent 9078761 commit e427d0a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion addons/hw_drivers/tools/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ def odoo_restart(delay):
def path_file(filename):
platform_os = platform.system()
if platform_os == 'Linux':
return Path().absolute().parent.joinpath(filename)
return Path.home() / filename
elif platform_os == 'Windows':
return Path().absolute().parent.joinpath('server/' + filename)

Expand Down

0 comments on commit e427d0a

Please sign in to comment.