Fixed several bugs with base quotes