Fix some issues in implementation
Use faster way to check for properties