Minor problem, updated code

Removed redundant #endif