File tree Expand file tree Collapse file tree 4 files changed +5
-2
lines changed
StackApis.ServiceInterface Expand file tree Collapse file tree 4 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ public object Get(SearchQuestions request)
1212 {
1313 var query = Db . From < Question > ( ) ;
1414
15- if ( request . Tags != null && request . Tags . Length > 0 )
15+ if ( request . Tags != null && request . Tags . Count > 0 )
1616 {
1717 query . Join < QuestionTag > ( ( q , t ) => q . QuestionId == t . QuestionId )
1818 . Where < QuestionTag > ( x => Sql . In ( x . Tag , request . Tags ) ) ;
Original file line number Diff line number Diff line change 11using System . Collections . Generic ;
22using ServiceStack ;
3+ using ServiceStack . DataAnnotations ;
34using StackApis . ServiceModel . Types ;
45
56namespace StackApis . ServiceModel
67{
8+ [ Description ( "Get a list of Answers for a Question" ) ]
79 [ Route ( "/getanswer/{QuestionId}" ) ]
810 public class GetAnswers : IReturn < GetAnswersResponse >
911 {
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ namespace StackApis.ServiceModel
77 [ Route ( "/questions/search" ) ]
88 public class SearchQuestions : IReturn < SearchQuestionsResponse >
99 {
10- public string [ ] Tags { get ; set ; }
10+ public List < string > Tags { get ; set ; }
1111 public string UserId { get ; set ; }
1212 }
1313
Original file line number Diff line number Diff line change 1313using ServiceStack . Text ;
1414using ServiceStack . Web ;
1515using StackApis . ServiceInterface ;
16+ using StackApis . ServiceModel ;
1617using StackApis . ServiceModel . Types ;
1718
1819namespace StackApis . Tests
You can’t perform that action at this time.
0 commit comments