I have an sql query, and I can find _NOTHING_ wrong with it:

Code:
SELECT * FROM `users` WHERE `username` = 'Dan' AND `password` = 'LiTkJ6hnGbvNc'
SQL Error:
Code:
Line: 486
File: /home/enumeric/public_html/live/inc/class_core.php
Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''Dan' AND `password` = 'LiTkJ6hnGbvNc'' at line 1
SQL Passed: SELECT * FROM `users` WHERE `username` = 'Dan' AND `password` = 'LiTkJ6hnGbvNc'
Function called:
PHP Code:
function sql_query$query // Simple holdall for mysql queries + err.
    
{
        
$query $this->clean$query);
        
$query str_replace"[apos]""'"$query );
        return @
mysql_query$query // Query will _only_ be cleaned at level 2. (NO HIGHER!)
        
or exit( "<strong>Line:</strong> " __LINE__ "<br /><strong>File:</strong> " __FILE__ "<br /><strong>Error: </strong>" mysql_error() . "<br /><strong>SQL Passed: </strong>$query);
    } 
-_-'