/** * Start a search subscription! * * @param profile $profile subscriber * @param string $search subscribee * @return SearchSub */ static function start(Profile $profile, $search) { $ts = new SearchSub(); $ts->search = $search; $ts->profile_id = $profile->id; $ts->created = common_sql_now(); $ts->insert(); self::blow('searchsub:by_profile:%d', $profile->id); return $ts; }