fixes + inline documentation