add last function for debug