workflow permission bug fixes