Fix casting issues with stream properites