Fix for bug in 66d28f04c79aa24bbdecd3863732f12767f25ea5