Replaced deprecated 'sys' function with 'paths' function