Socket update - making code able to import to anyone's project