Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible issue with PropelORMAdapter #44

Open
richrosa opened this issue Dec 23, 2011 · 0 comments
Open

Possible issue with PropelORMAdapter #44

richrosa opened this issue Dec 23, 2011 · 0 comments

Comments

@richrosa
Copy link

In sfMelodyUserClass->getDbTokens(), the function looks for an array of db_tokens as supplied by the underlying ORM method findByUserId. The request is expecting an array of tokens related to user_id from the token table, but findByUserId only returns a single object.

To solve this, I overrode in sfMelodyPropelOrmAdapter.

   public function findByUserId($user_id) {         
    $c = new Criteria; 
    $c->add(TokenPeer::USER_ID, $user_id); 
    return TokenPeer::doSelect($c); 
}

If this fixes a bug, I'll make a pull request and fix it and close the bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant