renamed variable to avoid confusion
Fixed option merging
Separated tags from fields