fixed copyright
adding support for custom queries (not fully finished yet)