Commit b664a0db authored by yiqinguo's avatar yiqinguo

Add err judgment

parent 637cc0a8
...@@ -180,7 +180,10 @@ func (c *realRecyclerClient) Event(eventtype, message string) { ...@@ -180,7 +180,10 @@ func (c *realRecyclerClient) Event(eventtype, message string) {
} }
func (c *realRecyclerClient) WatchPod(name, namespace string, stopChannel chan struct{}) (<-chan watch.Event, error) { func (c *realRecyclerClient) WatchPod(name, namespace string, stopChannel chan struct{}) (<-chan watch.Event, error) {
podSelector, _ := fields.ParseSelector("metadata.name=" + name) podSelector, err := fields.ParseSelector("metadata.name=" + name)
if err != nil {
return nil, err
}
options := metav1.ListOptions{ options := metav1.ListOptions{
FieldSelector: podSelector.String(), FieldSelector: podSelector.String(),
Watch: true, Watch: true,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment