fix environment packet sending