More compact & clean
Fixed socket init (promise)