fix small bugs, make sfig client/server side more compatible