Impove code quality for subnet code