fixed bug in get opt reserve
merged changes