Fix unwrapping bug